Note that there are some explanatory texts on larger screens.

plurals
  1. POUse Jquery to prevent page reloading pressing anchor
    primarykey
    data
    text
    <p>I am trying to use the jquery to Prevent page realoading. I have the whole code php done... and is functional. if you can please go to <a href="http://www.jonathansconstruction.com/gallery3.php" rel="nofollow">http://www.jonathansconstruction.com/gallery3.php</a> and click on the different gallery SUbmenus for category View All, Kitchen etc... i'm using get for variables. However, I would like to use a jquery to process the php so i dont have to include it into the gallery.php and also, to prevent page reloading because it brings the page back up and that could be confusing. Any hlep willl be greatly appreciated THanks</p> <p>UPDATE, Thanks for everyone that helped: </p> <p>SO far i made an advance on the website, Corrected URL was edited on top of the post</p> <p>Everything is working smoothly on the effects of quicksand.. HOwever, Lytebox Doesn't Load when a quicksand effect is placed. , at the beginning it loads just fine, but right after pressing one of the menus for the quicksand effect. It stops working. Also, I want to style my menu buttons as is in <a href="http://www.jonathansconstruction.com/gallery.php" rel="nofollow">http://www.jonathansconstruction.com/gallery.php</a>. I see jquery doesnt add and <li> witht the sample I downloaded. and also the that says "gallery Pictures" dissapears ont he quicksand demo.</p> <p>Any Help is appreciated. Below is the script.js code I have modified so far</p> <pre><code>$(document).ready(function(){ var items = $('.photo_show figure'), itemsByTags = {}; // Looping though all the li items: items.each(function(i){ var elem = $(this), tags = elem.data('tags').split(','); // Adding a data-id attribute. Required by the Quicksand plugin: elem.attr('data-id',i); $.each(tags,function(key,value){ // Removing extra whitespace: value = $.trim(value); if(!(value in itemsByTags)){ // Create an empty array to hold this item: itemsByTags[value] = []; } // Each item is added to one array per tag: itemsByTags[value].push(elem); }); }); // Creating the "Everything" option in the menu: createList('View All',items); // Looping though the arrays in itemsByTags: $.each(itemsByTags,function(k,v){ createList(k,v); }); $('#gallery_menu nav a').live('click',function(e){ var link = $(this); link.addClass('current').siblings().removeClass('current'); // Using the Quicksand plugin to animate the li items. // It uses data('list') defined by our createList function: $('.photo_show').quicksand(link.data('list').find('figure'), {adjustHeight: 'dynamic'} ); e.preventDefault(); }); $('#gallery_menu nav a:first').click(); function createList(text,items){ // This is a helper function that takes the // text of a menu button and array of li items // Creating an empty unordered list: var ul = $('&lt;ul&gt;',{'class':'hidden'}); $.each(items,function(){ // Creating a copy of each li item // and adding it to the list: $(this).clone().appendTo(ul); }); ul.appendTo('.photo_show'); // Creating a menu item. The unordered list is added // as a data parameter (available via .data('list'): var a = $('&lt;a&gt;',{ html: text, href:'#', data: {list:ul} }).appendTo('#gallery_menu nav'); } }); </code></pre> <p>ANOTHER EDIT : </p> <p>All Looking good So far Fixed Lot of problems, However, for some reason, the span I had on teh static html dissapears from display and even html code when loading jquery quicksand code..?? Here is the code i have on the html part of the website that Does Not appear on the live website for some reason.</p> <pre><code>&lt;div id="portfolio"&gt; &lt;div class="photo_show"&gt;&lt;span&gt;Gallery Pictures&lt;/span&gt; </code></pre> <p>the span part doesnt appear, dont know why</p> <p>I had the TOp Part Resolvd. just moved the on top of photo_show div and edited positioning... HOPEFULLY Last Edit the jquery for quicksand made my calendar dissapear, checked and yes it was some jquery conflict but dont know what can be causing it.. also the form validation not working as well ... any help is appreciated! </p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload