• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Problems with "write_file" and HTML Code

#1
[eluser]Unknown[/eluser]
Hi there,

I've a problem with the "write_file" function of the File Helper.

I'll try to explain:

I'm currently creating a little code editor for a template system in my CMS, made with CodeIgniter. My template system has some special tags, used to replace them with dynamic content.

Now, that's the problem. When I change something in the file (using CodePress as HTML Editor) I have some problems with the resulting code.

Here's an example:

before the edit I have:

Code:
<div id="logo">
        <a href="&lt;$site:index$&gt;"><img src="&lt;$site:base$&gt;assets/images/logo.jpg" alt="" /></a>  
    </div>

and there is what I have after:

Code:
<div id="logo">
        <a >"><img >assets/images/logo.jpg" alt="" /></a>  
    </div>

I think this is a special characters related problem, considering also that in the final saved file I can see things like this:

Before:
Code:
&lt;html&gt;

After:
i cannot see < or > symbols, in the code I find the &(less than) or &(greater than) equivalent.

That's all, hope I was clear in my speech. Anyone can help me?

Thanks for everything!


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.