Forum Moderators: open

Message Too Old, No Replies

Inserting script into HTML

         

Aderline

8:03 am on Jul 19, 2017 (gmt 0)

5+ Year Member



Hi to all :)

I would like to add script between paragraphs which gets pulled from mysql database.

<header>
<div content>
<p>T</p>
<p>T2</p>
</div content>
<footer>

The template looks like this, I can add add script above and under <div content> tag. The <div content> gets taken from mysql database.

How could I add script between the <p> tags? What are the options? How could I change the template so it would affect all the pages?

All info is appreciated.

Thank you very much!

Aderline

keyplyr

9:25 am on Jul 19, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Hi Aderline and welcome to WebmasterWorld [webmasterworld.com]

NickMNS

1:13 pm on Jul 19, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Hi Aderline, some more specific would be helpful to provide you with a useful answer.

What scripting language are you asking about, PHP or JS or something else?
When should the content be added, before the page loads (server side), when the page loads, or after with some trigger like on scroll or click?

Aderline

2:09 pm on Jul 19, 2017 (gmt 0)

5+ Year Member



Itīs PHP... I am trying to add ads between the text paragraphs... I can modify the template page but the content is taken from database as one block...