Closed Jimmi08 closed 7 years ago
After more testing. Gallery plugin with enabled SEF URL has the same problem: without SEF URL:
with SEF URL:
e_BASE is for files (includes etc.), not for URLs. The same for e_PLUGIN (file-system) vs e_PLUGIN_ABS (links). If you find them, please replace.
This code is in 12 files:
<a href='".e_BASE."user.php
I would replace it if I know how.
@CaMer0n waw, with this I think I am able to replace others. Just quick question, why did you use e107::getUrl()->create() and not e107::url()?
@Jimmi08 Some of the core is still using the older more complex/advanced method of creating SEF Urls. (news, page, search, system and user still use this). e107::url() is a newer, simpler developer-friendly method for doing the same thing.
@CaMer0n I am replacing e_BASE now (with user.php), is it possible (when I comment line with e_BASE code) to replace it f.e to ex_BASE, just not have already done code in searching result? I use Total Commander,it is going throught commented code too.
I don't know if this is the same issue as I am having, But here we go.
On a website, I use the donation plugin AnteUp - when I go to the forums or downloads everything is okay, but going into a download catagory or forum catagory the menu donate image and link are broken, at first I thought it was the theme and went looking and found nothing, then started looking at what pages affected the image and url.
So in downloads the url is: www.myurl.com/download/category/5/patches
PHP Firebug shows the HTML for the menu plugin like this: (removed the <'s and >'s to show the code)
a href="e107_plugins/anteup/donate.php"
img style="border:none" title="donate.gif" src="e107_plugins/anteup/images/icons/donate.gif"
/a
But mouse over the broken image displays the url as this: www.myurl.com/download/category/5/e107_plugins/anteup/donate.ph
Sounds like AnteUp is not using e_PLUGIN_ABS, but e_PLUGIN for its links?
Sounds like AnteUp is not using e_PLUGIN_ABS, but e_PLUGIN for it's links?
Correct. Fixed now (@LaocheXe you can redownload the latest files from the AnteUp repository and it should be fixed)
Closing this, I will create new issue if I notice next one. Thanks to all.
Sorry for bringing this up again, but it seems this bug is still around....
I got this strange behaviour in a SEF url forum page (ie: _websiteroot/forum/track):
Url HTML: <a href="top.php?0.top.forum.10">Top Posters</a>
Link shown by Firefox: _websiteroot/forum/top.php?0.top.forum.10
Which after click gives a error and i'm redirected to forum main page...
With a normal url page (ie: _websiteroot/e107_plugins/forum/forum.php?f=track):
Url HTML: <a href="../../top.php?0.top.forum.10">Top Posters</a>
Link shown by Firefox: _websiteroot/top.php?0.top.forum.10
Which after click is shown the correct top.php page...
Further more, the e_BASE constant is defined with regular url page, but with SEF one's it simply is not defined...
When you use SEF URLS you are basically in the root directory the entire time, and include files from elsewhere. Using e_BASE for a URL is bad practice. e_BASE is a FILE path, not a URL path.
What needs to be corrected is the URL in the forum shortcode sc_userinfo()
e_HTTP usually works as a replacement or SITEBASEURL (if I remember well )
@CaMer0n Well, SITEBASEURL doesn't work, it returns itself ("SITEBASEURL"). Ended up working with e_HTTP....
@rica-carv I am closing this. If there is still problem with SITEBASEURL, it's something different, please, create new issue. Thanks
I noticed weird thing with my plugins
(Just only with mine, so I do something wrong). The same with new plugin or with rewriting old one.e_BASE is empty. With other plugin (gallery, download) there si value ../..
I found the reason here (code is from e107_class.php).
~~With other plugins currect directory is correct C:\xampp\htdocs\e107V2\e10720150123\e107_plugins\gallery with my plugins C:\xampp\htdocs\e107V2\e10720150123 but url is f.e http://localhost/e107V2/e10720150123/links_page/links~~
Otherwise everything works. I noticed it just because using lastnews_menu first time and there is path done old way with e_BASE and with empty e_BASE is incorrect.
Without e_url.php path is correct, but e_url.php code seems to be allright, works very well.
I don't know where or what to look. Any idea? Thanks