Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Page 2 of 2 FirstFirst 12
Results 16 to 25 of 25
  1. #16
    Senior Coder
    Join Date
    Jan 2011
    Location
    Missouri
    Posts
    4,579
    Thanks
    23
    Thanked 643 Times in 642 Posts
    attr() is a jquery method. .attr( attributeName, value ) it assigns or changes an attribute.

    ‘rel’ describes the relationship between the current document and the document or anchor specified in the href attribute. We see it in <link rel="stylesheet" type="text/css" href="something.css" />, but it is misused all over. This may be one of those cases.

    The attr('rel', 'gallery') is used to unite a group of images with the rel being an attribute and every image to be linked has rel set to the same value.

    =======================
    can you give me a comment on each of these fields
    Don't have to they are explained in the documents http://fancyapps.com/fancybox/#docs
    Evolution - The non-random survival of random variants.

    "If you leave hydrogen alone, for long enough, it begins to think about itself."

  2. #17
    Regular Coder
    Join Date
    Jan 2011
    Posts
    302
    Thanks
    7
    Thanked 0 Times in 0 Posts
    hi - thanks, I looked at the documentation of fancybox - its great if you understand what they are writing.
    I was taking some more jquery classes this am and now have a pretty good understanding of what an attribute is - thanks.
    next question - this gallery thing - can I use a galery also on the same page with code we have put the youtube video on? Sometimes my entertainer of the month has pix and a gallery with a image next to the youtube video image would be the perfect solution for this place - oh, I am taking classes from
    the New Boston on YouTube for the jquery - which I think is cool.
    Fancybox is not great on customer service and has no forum either.

  3. #18
    Senior Coder
    Join Date
    Jan 2011
    Location
    Missouri
    Posts
    4,579
    Thanks
    23
    Thanked 643 Times in 642 Posts
    Fancybox is not great on customer service and has no forum either.
    and they are hard to understand too.

    Don't think of rel = 'gallery' as a gallery of paintings. 'Gallery' just groups things together, we could have used the word 'butter_milk' to group them.

    Good for you with thenewboston jquery tutorials. Don't forget to do the same with javascript just so you can fill in the gaps.
    Evolution - The non-random survival of random variants.

    "If you leave hydrogen alone, for long enough, it begins to think about itself."

  4. Users who have thanked sunfighter for this post:

    CoolKay (04-23-2013)

  5. #19
    Regular Coder
    Join Date
    Jan 2011
    Posts
    302
    Thanks
    7
    Thanked 0 Times in 0 Posts
    I started with the javascript course at udemy.com - found it boring and confusing. But I know I gotta go back. ah my brain is resisting javascript.
    Anyway can I put a fancybox gallery (for photos) and fancybox video on the same entertainersforhire.php page? or just one or the other? would the javascript file be the same or does the gallery need a new javascript ? ultimately I would like both on this page http://www.countyfairgrounds.net/ent...ersforhire.php - I think its pretty explanatory as to why - is it possible?

  6. #20
    Senior Coder
    Join Date
    Jan 2011
    Location
    Missouri
    Posts
    4,579
    Thanks
    23
    Thanked 643 Times in 642 Posts
    Kay what editor are you using to code?

    Here is an example of the video plus a group of pictures. Note I used a different "rel=" on the last picture. Play with it and then remove the A from the last picture to make it part of the group and check it out again.
    You can add another group of pictures by changing the class to various2 and so on.

    Take time and play with it if your going to use it. Try removing the border, try making it auto change.....

    You have to get comfortable with it in order to use it.
    Evolution - The non-random survival of random variants.

    "If you leave hydrogen alone, for long enough, it begins to think about itself."

  7. #21
    Regular Coder
    Join Date
    Jan 2011
    Posts
    302
    Thanks
    7
    Thanked 0 Times in 0 Posts
    I am using notepad ++ - best I have found and have used quite awhile
    Did you send code in the last email cause I did not get it

  8. #22
    Senior Coder
    Join Date
    Jan 2011
    Location
    Missouri
    Posts
    4,579
    Thanks
    23
    Thanked 643 Times in 642 Posts
    I thought I did send it. Guess I was wrong. Like that's not the first time.
    Code:
    <!DOCTYPE html>
    <html>
    <head>
    <title>fancyBox</title>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <link rel="stylesheet" type="text/css" href="../source/jquery.fancybox.css" media="screen" />
    <link rel="stylesheet" type="text/css" href="../source/jquery.fancybox.pack.js" media="screen" />
    <!-- Add jQuery library -->
     <script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
    <script type="text/javascript" src="../source/jquery.fancybox.js"></script>
    <script type="text/javascript" src="../source/helpers/jquery.fancybox-buttons.js?v=1.0.5"></script>
    <script type="text/javascript" src="/js/fancybox-1.3.4/jquery.mousewheel-3.0.4.pack.js"></script>
    <script type="text/javascript" src="../source/helpers/jquery.fancybox-thumbs.js?v=1.0.7"></script>
    <script type="text/javascript">
    $(document).ready(function() {
    		$(".various").fancybox({
    		maxWidth	: 800,
    		maxHeight	: 600,
    		fitToView	: false,
    		width		: '70%',
    		height		: '70%',
    		autoSize	: false,
    		closeClick	: false,
    		openEffect	: 'none',
    		closeEffect	: 'none'
    	});
    	
    		$(".various1").fancybox({
    		maxWidth	: 500,
    		maxHeight	: 500,
    		fitToView	: false,
    		width		: '70%',
    		height		: '70%',
    		autoSize	: true,
    		closeClick	: true,
    		openEffect	: 'none',
    		closeEffect	: 'none'
    	});
    });	
    </script>
    
    </head>
    <body>
    	<a class="various fancybox.iframe" href="http://www.youtube.com/embed/QzGyjGff-Q4?autoplay=1">
    	<img style="alt="J.J. Harrison Rodeo Clown" src="http://www.countyfairgrounds.net/images/rodeoclownvideo.png">
    	</a>
    	
    <p>
    Image gallery <small>(ps, try using mouse scroll wheel) </small><br />
    	<a class="various1 fancybox.iframe" rel="example_group" title="Custom title" href="http://farm3.static.flickr.com/2641/4163443812_df0b200930.jpg">
    		<img alt="" src="http://farm3.static.flickr.com/2641/4163443812_df0b200930_m.jpg" />
    	</a>
    	<a class="various1 fancybox.iframe" rel="example_group" title="" href="http://farm3.static.flickr.com/2591/4135665747_3091966c91.jpg">
    		<img alt="" src="http://farm3.static.flickr.com/2591/4135665747_3091966c91_m.jpg" />
    	</a>
    	<a class="various1 fancybox.iframe" rel="example_groupA" title="" href="http://farm3.static.flickr.com/2561/4048285842_90b7e9f8d1.jpg">
    		<img alt="" src="http://farm3.static.flickr.com/2561/4048285842_90b7e9f8d1_m.jpg" />
    	</a>
    </p>	
    </body>
    </html>
    Evolution - The non-random survival of random variants.

    "If you leave hydrogen alone, for long enough, it begins to think about itself."

  9. #23
    Regular Coder
    Join Date
    Jan 2011
    Posts
    302
    Thanks
    7
    Thanked 0 Times in 0 Posts
    Hi and thanks - what do you mean by this line
    ps, try using mouse scroll wheel ?

  10. #24
    Senior Coder
    Join Date
    Jan 2011
    Location
    Missouri
    Posts
    4,579
    Thanks
    23
    Thanked 643 Times in 642 Posts
    With Fancybox your scroll wheel can cycle though the picture gallery. Try doing that.
    Evolution - The non-random survival of random variants.

    "If you leave hydrogen alone, for long enough, it begins to think about itself."

  11. #25
    Regular Coder
    Join Date
    Jan 2011
    Posts
    302
    Thanks
    7
    Thanked 0 Times in 0 Posts
    some great progress

    http://www.countyfairgrounds.net/tes...nersphotos.php

    with my page http://www.countyfairgrounds.net/ent...ersforhire.php

    what I am trying to do is like have one image and maybe above it click here for gallery pix of this months entertainer. - Can we do that? I also am not too sure as to how they got the image titles in the photos.


 
Page 2 of 2 FirstFirst 12

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •