willbeeler
willbeeler

Reputation: 689

TinyMce + Ajax File Manager + Codeigniter = Little Problem

OK, I'm using the following:

TinyMCE, CodeIgniter, and the TinyMCE Ajax File Manager. I can upload correctly and it looks pretty good. However, when I view the HTML (from TinyMCE), this is what I get.

<img src="../../../data/page/verde_enfemera.jpg" alt="" />

What I need to be getting is the following:

<img src="http://localhost/http/data/page/verde_enfemera.jpg" alt="" />

Can someone help?

EDIT: I changed the code in the HTML editor of Tinymce, then I saved it. When I re-opened it, the code was reverted back to the original "../.../../data", etc. please, help, someone.

Upvotes: 0

Views: 3704

Answers (3)

Amr
Amr

Reputation: 5159

Force TinyMCE to use absolute urls instead of relative urls by setting relative_urls, remove_script_host and convert_urls to false in the tinymce.init like this:

tinymce.init({
    ...
    ...

    relative_urls : false,
    remove_script_host : false,
    convert_urls : false,

    ...
    ...
});

Upvotes: 0

hume
hume

Reputation: 11

insert convert_urls : false

Upvotes: 1

willbeeler
willbeeler

Reputation: 689

Change the "relative_urls : true" to "relative_urls : false" under the options for tinymce. I'm a dummy.

Upvotes: 0

Related Questions