adding div to php file

12 years 7 months ago #6564 by akay
I'm in the process of upgrading my Joomla site from 1.5 to 2.5. I've been able to reproduce all my old AJAX Scroller settings so far except for one.

For reference, you can see the old version of my scroller here: www.teamsdesign.com/com/

The element I'm having trouble with is the semi-transparent white square that appears behind the headline and in front of the main image.

In my old file, I had added this line of code into the file mod_ajaxscroller.php:
$content .= "<span class=\"title\">$title</span>\n <div id=\"headline_backer\"></div>";

The new PHP file seems quite a bit different from the old one. I can make the white square appear by adding this code to it:
$content .= '<div id="headline_backer"></div>';
BUT, I can't figure out the correct place to insert that code.

When I try inserting the code in different areas of the PHP file, the square does one of two things:
  • It does not scroll (it says still in the left corner -- the text scrolls over it and the image scrolls under it)
  • It does scroll, but it randomly disappears and reappears as it scrolls

I really don't know PHP -- I can just copy and paste code like a monkey -- so my apologies if this is a stupid question! Thank you!

If it makes a difference, I've been previewing the new site in Chrome.

-Amanda

Please Log in or Create an account to join the conversation.

About us

We provide high quality Joomla components created by a co-founder and original core developer of Joomla. For over a decade, our products have been used by more than 20.000 webmasters around the world.

Stay in touch