Where is documentation on how to add content to a website?

Asked by landysaccount

Hello.

I'm looking for a way to add a CSS div to the top of every page that passes through squid and read eCap can help to accomplish this. All I need to do is add something like:

<div class="something">
  <p>Whatever messege here</p>
</div>

to the top of every request made by clients.

Can I use php to rewrite the content?

I can't find any documentation on how to do this. If you can please guide me to where I can read about it I will appreciate it.

Thanks in advanced for your assistance. Please apologize if this is not the correct place to ask such questions.

Question information

Language:
English Edit question
Status:
Answered
For:
eCAP Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Alex Rousskov (rousskov) said :
#1

There is no documentation specific to your question, but there is a sample adapter that modifies HTTP response body content. You may enhance that code to make the necessary modifications to HTML response bodies. That sample adapter is included in the adapter sample tarball available for download here and on the e-cap.org site.

eCAP is a C++ API. I am not aware of any projects to provide PHP wrappers, but it is most likely possible. We have had a mostly successful Python wrapper pilot, and I am guessing wrapping PHP adapters would be similar.

Revision history for this message
gianni (gianni-olivieri) said :
#2

Hi,

   can you post an example? I'd like to add a customizable html code after (for example the body tag)... can someone post an example?

There is no documentation about it...

Revision history for this message
gianni (gianni-olivieri) said :
#3

Hi,

   can you post an example? I'd like to add a customizable html code after (for example the body tag)... can someone post an example?

There is no documentation about it...

Can you help with this problem?

Provide an answer of your own, or ask landysaccount for more information if necessary.

To post a message you must log in.