graham23s Posted July 31, 2007 Share Posted July 31, 2007 Hi GUys, what i was wanting to do is get data from mysql and scroll it like the html marquee but make it alot smoother and not as jerky can this be done with php at all? cheers guys Graham Quote Link to comment https://forums.phpfreaks.com/topic/62695-solved-marquee-using-php/ Share on other sites More sharing options...
piznac Posted July 31, 2007 Share Posted July 31, 2007 Something like this?: echo "<MARQUEE>$query_results_row[mydata]</MARQUEE>"; Not sure about making it smoother,.. you could play with the "SCROLLAMOUNT" tag to try and make it smoother. Quote Link to comment https://forums.phpfreaks.com/topic/62695-solved-marquee-using-php/#findComment-312047 Share on other sites More sharing options...
ss32 Posted July 31, 2007 Share Posted July 31, 2007 there are java/javascript implementations of the marquee you want to achieve, but the problem with using those is compatibility. I would just stick with the regular HTML marquee- it works. Quote Link to comment https://forums.phpfreaks.com/topic/62695-solved-marquee-using-php/#findComment-312050 Share on other sites More sharing options...
deadimp Posted July 31, 2007 Share Posted July 31, 2007 However, you may want to take a step back and ask yourself, "Why do I need marquees?" Having animated elements of a web page tends to distract the user from your site content, something you don't really need. The only time you should use animated elements is when they're relatively small and low-key (I guess a small, slow vertical ticker to the side), or they're animated in response to a user action. As for your original question, PHP doesn't really handle the dynamic element of marquees. PHP stands for PHP: Hypertext Preprocesor, meaning that all it does is output text (well, streams if you want to get technical, but you get the point). You'll need to learn other things to handle the client-side animations, such as the <marquee> tag like the others suggested, JavaScript (which for animation isn't really a good idea, unless it's in response to user input), and stuff of the like. Quote Link to comment https://forums.phpfreaks.com/topic/62695-solved-marquee-using-php/#findComment-312053 Share on other sites More sharing options...
graham23s Posted July 31, 2007 Author Share Posted July 31, 2007 thanks for the input guys, i think i will just stick to the normal marquee effect:) thanks guys Graham Quote Link to comment https://forums.phpfreaks.com/topic/62695-solved-marquee-using-php/#findComment-312176 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.