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 1 of 2 12 LastLast
Results 1 to 15 of 17
  1. #1
    New Coder
    Join Date
    Feb 2013
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Please please please help!!!

    Hi guys,

    I'm in such a difficult position. I've just started a new job and taken over from the old developer and I can't figure out how to remove the video from the first slide of the video player. I only want the images to show. Please help me do this as I really need to get this right. Your help would be greatly appreciated.

    Below is the .js slider code, and after that the xml code to grab the slider:

    PHP Code:
    //HOME SLIDER CREATION + ARTICLES
        
    var getHomeslider = function()
        {            
            var 
    sliderhtml '';
            
    sliderhtml += '<div><div id="home-holder">';
            
    sliderhtml += '<div><div id="home-holder-inner">';
            
            for (var 
    0sliderarray.lengthi++)
            {
                
    sliderhtml += '<div class="home-blurb">';
                
                if (
    sliderarray[i].video != 'null'
                {                                
                    if (
    IsIE == 1
                    {                
                        
    sliderhtml += '<div id="swf"></div>';

                    } else {
                        
    sliderhtml += '<video  id="trailer" width="' vidw '" height="' vidh '"  controls="controls" poster="' sliderarray[i].image '.jpg">';
                        
    sliderhtml += '<source src="' sliderarray[i].video '.mp4" type="video/mp4" /><source src="' sliderarray[i].video '.ogg" type="video/ogg" /> Your browser does not support the video tag.</video>';
                    }
                    
                } else {                
                    
    sliderhtml += '<div class="home-image"><img src="' sliderarray[i].image '.jpg" /></div>';
                    
    sliderhtml += '<div class="text-holder">';            
                    
    sliderhtml += '<div class="home-circle"><img src="assets/circle_ad.png" alt="production flash cta" /></div>';
                    
    sliderhtml += '<div class="home-blurb-subtitle">'sliderarray[i].subtitle '</div>';
                    
    sliderhtml += '</div>';
                }
                    
    sliderhtml += '</div>';
            } 
            
            
    sliderhtml += '</div></div>';
            
    sliderhtml += '<div id="prev-button"></div><div id="next-button"></div>';

            
    sliderhtml += '</div>';
            
            var 
    articlehtml '';
            
    articlehtml += '<div id="article">';
            
            for (var 
    0prodarray.lengthk++)
            {
                
    articlehtml += '<div class="article">';
                
    articlehtml += '<div class="article-image"><img src="'prodarray[k].thumb '" alt="'prodarray[k].title '" title="'prodarray[k].title '" /></div>';
                
    articlehtml += '<div class="article-sub">'prodarray[k].subtitle '</div>';
                
    articlehtml += '<div class="article-date">'prodarray[k].date '</div>';
                
    articlehtml += '<div class="article-more">Coming Soon</div>';            
                
    articlehtml += '</div>';
            }
            
            
    articlehtml += '</div>';
            
            var 
    myhtml = $('#content-main');
            
    myhtml.html(sliderhtml articlehtml);
            
            var 
    myw vidw;
            
    slidermax i;
            
    slidercount 0;
            
            $(
    '#home-holder').css({'height' vidh });
            $(
    '#home-holder-inner').css({'width' myw'height' vidh });

            $(
    '#next-button').on("click"moveslider).css({ 'margin-top' : -vidh });
            $(
    '#prev-button').on("click"moveslider).css({ 'margin-top' : -vidh });
            
            $(
    '.home-blurb a').css({'cursor' 'pointer' });
            $(
    '.home-circle').on("click", {foo "subscribe"}, overBtn).css({'cursor' 'pointer' });
                
            if (
    IsIE == 0)
            {    
                $(
    '#trailer').get(0).play();    
            
                $(
    'video').bind('ended', function(){
                    
    moveslider();
                    
    video.currentTime 0;
                    
                    
    trackEvent._trackEvent('globe''trailer''end');
                    
    trackEvent2._trackEvent('globe''trailer''end');
                });
                            
                
            } else {
                
    createSWFobject();
                
                $(
    '#next-button').css({ 'top' '310px' 'margin-top' });
                $(
    '#prev-button').css({ 'top' '310px' 'margin-top' });
            }
            
            $(
    '.article-more').css({'cursor' 'pointer' }); //.on("mouseenter", overBtn).on("mouseleave", overBtn);            
            
            
    setartHeight();    
        }
        
        var 
    createSWFobject = function ()
        {    
            var 
    params = {
                
    allowfullscreen"true"
                
    allowscriptaccess"always",
                
    wmode"transparent"
            
    };        
            
            var 
    flashvars = {
            
            };
            
            
    swfobject.embedSWF('player/player.swf''swf'vidwvidh"9""expressInstall.swf"flashvarsparams);
        } 





    XML File Code



    Code:
    <slider>
    			<subtitle><![CDATA[]]></subtitle>
    			<video>assets/BigScreenGlobe_860x900</video>
    			<image>assets/trailer_image</image>			
    		</slider>
    		
    		<slider>
    			<subtitle><![CDATA[Experience three incredible productions from the world's most famous stage at a cinema near you.<br>
    Venue information <a>coming soon</a>]]></subtitle>
    			<video>null</video>
    			<image>assets/globe</image>			
    		</slider>
    		
    		<slider>
    			<subtitle><![CDATA[UK/AUS/NZ/USA <a>In cinemas from May</a><br>
    Venue information coming soon]]></subtitle>
    			<video>null</video>
    			<image>assets/henry_v_carousel</image>		
    		</slider>
    		
    		<slider>
    			<subtitle><![CDATA[UK/AUS/NZ/USA <a>In cinemas from June</a><br>
    Venue information coming soon]]></subtitle>
    			<video>null</video>
    			<image>assets/muchado_carousel</image>			
    		</slider>
    		
    		<slider>
    			<subtitle><![CDATA[UK/AUS/NZ/USA <a>In cinemas from June</a><br>
    Venue information coming soon]]></subtitle>
    			<video>null</video>
    			<image>assets/taming_shrew_carousel</image>		
    		</slider>
    Last edited by VIPStephan; 03-01-2013 at 11:25 AM. Reason: added code BB tags

  • #2
    Regular Coder
    Join Date
    Jan 2013
    Location
    Germany
    Posts
    578
    Thanks
    4
    Thanked 77 Times in 77 Posts
    You want us to to your job for which you get paid? I mean you're not asking for help, you're simply asking us to do it.

  • #3
    New Coder
    Join Date
    Feb 2013
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Not at all, I'm asking for help so I can see how to fix it. I'm a beginner in .js so I thought this was the place to come for help.

  • #4
    Supreme Master coder! Philip M's Avatar
    Join Date
    Jun 2002
    Location
    London, England
    Posts
    17,898
    Thanks
    203
    Thanked 2,530 Times in 2,508 Posts
    Quote Originally Posted by fakierock View Post
    Not at all, I'm asking for help so I can see how to fix it. I'm a beginner in .js so I thought this was the place to come for help.
    If you want help here, you would be advised to follow the forum rules and guidelines. Many people will ignore people who cannot be bothered to comply with them.

    Do please read the posting guidelines regarding silly thread titles. The thread title is supposed to help people who have a similar problem in future. Yours is useless for this purpose. You can (and should) edit it to make it more meaningful.

    When posting here please help us to help you by making it easier to copy, test and debug your scripts by following the posting guidelines and wrapping your code in CODE tags. This means use the octothorpe or # button on the toolbar. You can (and should) edit your previous post.

    Your query relate to jQuery, so you would do best to post in the Jquery forum.

    But as airblader says, you ought not to ask for assistance of this kind in a job for which you are being paid. And there is no need to grovel.

    It is your responsibility to die() if necessary….. - PHP Manual

    All the code given in this post has been tested and is intended to address the question asked.
    Unless stated otherwise it is not just a demonstration.

  • #5
    New Coder
    Join Date
    Feb 2013
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Ok thanks, you're right I should have read the guidelines before but was in a panicked state of mind. I do appreciate I should have read them before I posted. I have no shame in admitting I was grovelling as I've been trying to figure out what the files mean, but maybe I should try and figure it out on my own. I will probably feel happier when I finally learn how to do it by trial and error myself.

    That said, I'm sure there have been times when experienced coders have run into similar problems. I will one day hopefully be able to help people who have similar problems that I have today, and as I have been there, I will help even if it means helping someone to keep their job. I will choose to share my future knowledge regardless of the reason of helping.

  • #6
    Supreme Master coder! Philip M's Avatar
    Join Date
    Jun 2002
    Location
    London, England
    Posts
    17,898
    Thanks
    203
    Thanked 2,530 Times in 2,508 Posts
    Quote Originally Posted by fakierock View Post
    Ok thanks, you're right I should have read the guidelines before but was in a panicked state of mind. I do appreciate I should have read them before I posted. I have no shame in admitting I was grovelling as I've been trying to figure out what the files mean, but maybe I should try and figure it out on my own. I will probably feel happier when I finally learn how to do it by trial and error myself.

    That said, I'm sure there have been times when experienced coders have run into similar problems. I will one day hopefully be able to help people who have similar problems that I have today, and as I have been there, I will help even if it means helping someone to keep their job. I will choose to share my future knowledge regardless of the reason of helping.
    I think that you will find that most people are reluctant to do other people's paid work for them. But you would perhaps have stood a better chance if you had not simply ignored the posting guidelines and not grovelled. That often turns people off.

    All the code given in this post has been tested and is intended to address the question asked.
    Unless stated otherwise it is not just a demonstration.

  • #7
    New Coder
    Join Date
    Feb 2013
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks, you're right, I should have read the guidelines and not panicked! I appreciate these forums are great places and I'll do things differently next time. I will give it a go, as I suppose a little trial and error never hurt anyone. It is probably the best way to learn.

  • #8
    Regular Coder
    Join Date
    Jan 2013
    Location
    Germany
    Posts
    578
    Thanks
    4
    Thanked 77 Times in 77 Posts
    I don't mind helping people with their paid work – but that requires a certain level of commitment to the question. Sorting out the essential from the irrelevant, showing what you have done yourself. That kind of stuff. All I see, though, is a big block of code and "Doesn't work. please help me".
    And as Philipp said, ignoring guidelines does not help either.

    If you took a job as a Javascript developer and you have no Javascript experience, your company should give you appropriate help and not just throw you into cold water having you do what you simply cannot do. Maybe this is something you better discuss with your boss, because even if someone solves this for you – how is this gonna help you with your next task?

  • #9
    New Coder
    Join Date
    Feb 2013
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi Airblader, thanks for your message. The problem is that I recently got this new job as a web developer. They know I am beginner developer, so It's not too important if I get this right. My main motivation is that I am really trying to be able to do it as I will feel so happy to have achieved something in development.

    I am able to build websites from scratch but the problem is that I'm trying to move from being a web designer to being a developer. I am really determined to do it, but finding it very hard. I am doing Lynda.com tutorials to learn, but there seems to be so many languages to choose from.

    If I had to build the site I'm currently working on from scratch, I would have no problem with building it, coding it but I just don't have the knowledge to understand how the previous developer built the site. It's very hard for me to make changes.

    To be honest I completely understand that my post was not acceptable in asking for help. Even if there was a tutorial to show me the ropes I would happily go through it.

  • #10
    New to the CF scene
    Join Date
    Mar 2013
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Even though I have completed my course in JS, I find it difficult to write these scripts. Instead I use the scripts found online and tweak them to suit my needs and that helps me a lot...

  • #11
    Senior Coder Logic Ali's Avatar
    Join Date
    Sep 2010
    Location
    London
    Posts
    1,028
    Thanks
    0
    Thanked 207 Times in 202 Posts
    From the way this script is configured, I would say all you have to do is comment-out the first <slider> element:

    Code:
    <!-- <slider>
    			<subtitle><![CDATA[]]></subtitle>
    			<video>assets/BigScreenGlobe_860x900</video>
    			<image>assets/trailer_image</image>			
    </slider> -->

  • #12
    New Coder
    Join Date
    Feb 2013
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi Logic Ali, thanks very much for your response. I thought the same but when I comment it out the next and prev buttons no longer work. I appreciate you getting back to me about this as I've been trying to figure it out for 2 days! I will keep trying!

  • #13
    Senior Coder Logic Ali's Avatar
    Join Date
    Sep 2010
    Location
    London
    Posts
    1,028
    Thanks
    0
    Thanked 207 Times in 202 Posts
    Quote Originally Posted by fakierock View Post
    Hi Logic Ali, thanks very much for your response. I thought the same but when I comment it out the next and prev buttons no longer work.
    Do you get any console errors when that happens?

  • #14
    New Coder
    Join Date
    Feb 2013
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi Logic Ali, I don't get any errors, just the next and prev buttons don't work and the style of the video player seems to change. I've been wracking my brain all day since yesterday. I think I'm starting to see grey hair!

    I've been trying to change the main.js file too, but as I'm new to development it's very difficult to understand.

  • #15
    New Coder
    Join Date
    Feb 2013
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi guys, just thought I'd shout with joy and say I fixed the problem completely! It was, in hindsight a very simple fix. I just had to look more closely at the main.js file and comment out a lot of the script which then when I commented out the first slider code fixed the problem.

    Never give up!


  •  
    Page 1 of 2 12 LastLast

    Posting Permissions

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