Jump to content
php.lv forumi
  • 0

Jquery dažādas versija vajadzīgas...


reiniger

Question

Sveiki.

 

Ir sekojoša lieta, ka pamata lapā ir jparallax plugins

<script type="text/javascript" src="jquery-1.2.6.min.js"></script>
<script type="text/javascript" src="jquery.jparallax.js"></script>

Bet ar .load() ielādējot man lapu, taja Pirobox nestrādā kā ritīgi vajag. (Neredz pareizu attēlu navigāciju pie pirmā attēla ļauj apskatīt iepriekšējo un kad to nospiež, tad pazūd visa navigācija un tikai refresh palīdz izkļūt no Pribox.)

 

Bet Pirobox pareizi strādā ar

<script type="text/javascript" src="http://code.jquery.com/jquery-latest.js"></script>

 

Bet ar jquery-latest.js man nestrādā jparallax!

 

Kā panākt lai man jparallax un Pirobox varētu strādāt vienlaicīgi?

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0

Neliels ieskats koda:

###pamata lapa:
...
<script type="text/javascript" src="jquery-1.2.6.min.js"></script>
<script type="text/javascript" src="jquery.jparallax.js"></script>
<script type="text/javascript">
jQuery(document).ready(function(){
jQuery('#parallax').jparallax({});
});

function openProject( idv ){
   $('#atvertsprojekts').load('project.php?id=' + idv, function() {
       $(this).show();
   });    
   return false;
};

</script>

<div id="atvertsprojekts" style="display: none;"></div>

<div id="parallax">
       <div style="width:<?=$width_arr[$count_ch]*411?>px; height:735px;">
           <ul>

             <li><a onclick="openProject(1)" style="background-image:url('pictures/1.jpg');"><img src="pictures/1.jpg" alt="" /></a></li>  
             <li><a onclick="openProject(2)" style="background-image:url('pictures/2.jpg');"><img src="pictures/2.jpg" alt="" /></a></li>  
           </ul>
        </div>
</div>
....

####   project.php lapa

<script type="text/javascript" src="http://code.jquery.com/jquery-latest.js"></script>
<script type="text/javascript" src="pirobox.1_2.js"></script>
<script type="text/javascript"> 
var piroBox = 0;
$().piroBox({
.....
</script>

Edited by reiniger
Link to comment
Share on other sites

  • 0

Milzīgs paldies indoom. Labojums lai strādātu.

<script type="text/javascript" src="http://code.jquery.com/jquery-latest.js"></script>
<script type="text/javascript" src="jquery-1.2.6.min.js"></script>
<script type="text/javascript" src="jquery.jparallax.js"></script>
<script type="text/javascript">
jQuery.noConflict();
(function($) { 
 jQuery(document).ready(function(){
jQuery('#parallax').jparallax({});
 });
})(jQuery);

function openProject( idv ){
   $('#atvertsprojekts').load('project.php?id=' + idv, function() {
       $(this).show();
   });    
   return false;
};
</script>

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...