Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#73 2005-09-01 04:40:41

alicson
Member
Registered: 2004-05-26
Posts: 465
Website

Re: rsx_frontend_edit: Frontend Edit Link

hi.. looks like there might be a slight error… there’s a missing “/”

href="'.$hu.'textpattern/index.php?
should be
href="'.$hu.'/textpattern/index.php?

thanks for updating the plugin, ramanan. colak’s right; your plugins are extremely useful.


textpattern.org :: find and share Textpattern resources
docs.textpattern.io :: Textpattern user documentation

Offline

#74 2005-09-01 04:54:08

ramanan
Plugin Author
From: Toronto
Registered: 2004-03-12
Posts: 323
Website

Re: rsx_frontend_edit: Frontend Edit Link

I think the trailing slash should be part of the “subdirectory” field in the admin tab, no? If not, then you are right, this would be incorrect. I’m looking at my old version, and it also was missing the the slash. How do people normally run things?

And my pleasure to update stuff. I feel like i’ve been absent from the TXP community for a while. Next step is to upgrade to 4.0.

Offline

#75 2005-09-01 05:50:33

alicson
Member
Registered: 2004-05-26
Posts: 465
Website

Re: rsx_frontend_edit: Frontend Edit Link

it’s not the trailing slash.. it’s the slash before textpattern = /textpattern .. right?
cuz without that / to send to the root url, it just appends textpattern/indes.php? onto whichever page you’re currently on. sorry i wasn’t clear earlier…
thanks again.


textpattern.org :: find and share Textpattern resources
docs.textpattern.io :: Textpattern user documentation

Offline

#76 2005-09-01 07:00:27

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,012
Website GitHub Mastodon Twitter

Re: rsx_frontend_edit: Frontend Edit Link

I have my txp installed in a subdirectory and it works jus fine without the slash… I’m not saying that it shouldn’t be there. I’m just thinking:)


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#77 2005-09-01 09:36:37

ramanan
Plugin Author
From: Toronto
Registered: 2004-03-12
Posts: 323
Website

Re: rsx_frontend_edit: Frontend Edit Link

Yeah. I think that isn’t needed, because the variable should contain the slash. For example, on my site where Textpattern is in the root folder, my variable is set to “/”. But if it was in a directory called weblog, it would be set to “weblog/”.

Offline

#78 2005-09-01 11:23:22

graumeister
Plugin Author
From: Ban Bang Por, Samui, Thailand
Registered: 2005-01-16
Posts: 167
Website

Re: rsx_frontend_edit: Frontend Edit Link

@ramanan: put a str_replace(‘//’,’/’, $varnameoftheurl) around the url and the // will be gone if someone has put the trailing slash in the settings. it is better to do this, because without slash it could be really a problem and you never know what the user put there :) (it could also be a “/path/to/subdirectory” without the end-slash.


Samui? Samui! (about the life as farang in thailand)
David’s Neighbour

Offline

#79 2005-09-01 13:39:59

alicson
Member
Registered: 2004-05-26
Posts: 465
Website

Re: rsx_frontend_edit: Frontend Edit Link

in 4.0, i don’t think there’s a separate option for setting a subdirectory… you just put the whole home url in one field, which instructs that a closing slash is not necessary.

i don’t doubt that it’s working for for you guys without the slash — i’d wondered why i should be the first to mention it. but it definitely was on tworking for me until i noticed the missing slash. it worked when i used the ‘frontend edit’ link from my first page, but from any other page, it would just tag textpattern/index.php?event=article&step=edit&ID=889 onto the end of the existing URL already up in the address bar… so it wasn’t working for me at all. Now that the one slash is added in the plugin code, it’s working dandily for me. i wonder if there might be anything different with my installation to cause this different result for me. i’ve not experienced it besides, though..

anyway, that’s my experience.


textpattern.org :: find and share Textpattern resources
docs.textpattern.io :: Textpattern user documentation

Offline

#80 2005-09-03 00:18:44

ramanan
Plugin Author
From: Toronto
Registered: 2004-03-12
Posts: 323
Website

Re: rsx_frontend_edit: Frontend Edit Link

Thanks Alicson. I’ll work on that when I get home then. I had only tested things from the front page and assumed it was all good.

Offline

#81 2005-09-03 06:12:08

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,012
Website GitHub Mastodon Twitter

Re: rsx_frontend_edit: Frontend Edit Link

hi all just to let you know that mine works everywhere ie front page, article lists, individual articles and search results.


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#82 2005-09-03 14:15:05

ramanan
Plugin Author
From: Toronto
Registered: 2004-03-12
Posts: 323
Website

Re: rsx_frontend_edit: Frontend Edit Link

I’m not at home for the weekend, so I can’t test out my txp 4.0 install till i’m back. I need to look up where the $hu variable is set.

update: The $hu variable should always contain a trailing slash as far as I can tell. Can anyone else confirm this problem? I might be misreading the source code. (See index.php line 64)

Last edited by ramanan (2005-09-04 02:05:04)

Offline

#83 2005-09-04 07:37:14

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,012
Website GitHub Mastodon Twitter

Re: rsx_frontend_edit: Frontend Edit Link

A very small unimportant thing… The &s in the last line create a non valid html document
ie In the line
<code><a href=”’.$pfr.‘textpattern/index.php?event=article&step=edit&ID=’.$thisarticle[‘thisid’].’”>’.parse($thing).’</a>’.$suffix.’\’;} ?>’;</code>
all the “&“s could be replaced with <code>& amp;</code>

Last edited by colak (2005-09-04 07:40:45)


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#84 2005-09-04 13:18:08

ramanan
Plugin Author
From: Toronto
Registered: 2004-03-12
Posts: 323
Website

Re: rsx_frontend_edit: Frontend Edit Link

Oh true. Mind you, someone would have to have turned on the frontend edit cookie before being shown any of the mark-up. I can fix that also while I look in to this missing slash thing more.

Offline

Board footer

Powered by FluxBB