Jump to content

Making "Read More" button


genu

Recommended Posts

HI, I am using PHP to get the articles from a database, and then JavaScript and Css to truncate them to a certain height. When they Click Read More...That article would expand to show the whole thing. Here is what I have so far: [a href=\"http://localhost:8080/youth.php\" target=\"_blank\"]http://localhost:8080/youth.php[/a]

I notice that the JavaScript or CSS is messed up in Firefox...why is that, and how do I fix. Furthermore...how can I make it so that the once they click "Read More", it turns in to "Read Less" and when they click "Read Less", it woul again truncate the descripiton.

thx in advance
Link to comment
https://forums.phpfreaks.com/topic/3483-making-read-more-button/
Share on other sites

Guess what? You're the only person on the planet that can connect to [a href=\"http://localhost:8080/youth.php\" target=\"_blank\"]http://localhost:8080/youth.php[/a]

Personally, I'd use Google and search for a simple javascript 'show/hide' script so that the div containing the news is either visible or not. Why your javascript/CSS doesn't work in some browsers is because your choices of js/CSS don't work in all browsers.
Link to comment
https://forums.phpfreaks.com/topic/3483-making-read-more-button/#findComment-11956
Share on other sites

[!--quoteo(post=347391:date=Feb 19 2006, 11:07 AM:name=AndyB)--][div class=\'quotetop\']QUOTE(AndyB @ Feb 19 2006, 11:07 AM) [snapback]347391[/snapback][/div][div class=\'quotemain\'][!--quotec--]
Guess what? You're the only person on the planet that can connect to [a href=\"http://localhost:8080/youth.php\" target=\"_blank\"]http://localhost:8080/youth.php[/a]

Personally, I'd use Google and search for a simple javascript 'show/hide' script so that the div containing the news is either visible or not. Why your javascript/CSS doesn't work in some browsers is because your choices of js/CSS don't work in all browsers.
[/quote]

im sorry...try genuchelu.redirectme.net/youth.php

what else can I use other than JavaScript, to get the same effect?
Link to comment
https://forums.phpfreaks.com/topic/3483-making-read-more-button/#findComment-11968
Share on other sites

[!--quoteo(post=347623:date=Feb 20 2006, 10:12 AM:name=ChrisDarl)--][div class=\'quotetop\']QUOTE(ChrisDarl @ Feb 20 2006, 10:12 AM) [snapback]347623[/snapback][/div][div class=\'quotemain\'][!--quotec--]
Flash?
[/quote]

I cant use flash, because the data is extracted from the database via php.
Link to comment
https://forums.phpfreaks.com/topic/3483-making-read-more-button/#findComment-11991
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.