Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: Improving...
Doh!
I just assumed that I still needed to approve my post (I didn’t even look at the comment status when I was messing around), but you’re absolutely right!
Excellent work, Juanjo – this is going to make a lot of people very happy..!
Keith
Blyth, Northumberland, England
Capture The Moment
Offline
Re: Improving...
Gocom wrote:
Remember to escape the insert queries. Currently the web, email and name…
Ok.
Maybe you don’t need to define globals for every page when they don’t do anything. Actually you don’t even need them for anything, because the code always calls the function directly (or could).
Globals? What do you mean?
The
txp_discuss.php
include is not required if you just point the form to the comment edit page with correct inputs.
Using a “Location” Header? The problem is that I cannot send the confirmation message to be printed using a redirect. Do I?
Offline
Re: Improving...
juanjonavarro wrote:
Globals? What do you mean?
$textarrray
. You could either define it inside the function (not outside of it) or then by just tranfering the form data with post from preview to submit ect. Currently the global is defined for whole backend.
juanjonavarro wrote:
Using a “Location” Header? The problem is that I cannot send the confirmation message to be printed using a redirect. Do I?
Well you could redirect, but not required. You only need to send the form to the correct page – for example to the same comment edit dialog was used to write the comment.
Yes, you can’t use pagetop()
nor the inbuild message system. But you could use own message that is shown somewhere alongside the form content, for example. Not as fancy tho.
Offline
Re: Improving...
Gocom wrote:
$textarrray
. You could either define it inside the function (not outside of it) or then by just tranfering the form data with post from preview to submit ect. Currently the global is defined for whole backend.
$textarray is the array of “literals” of textpattern. I’m just defining new literals so I can use them later with gTxt. I define them at the top so:
- It’s easier to translate it to your language when you install de plugin.
- Can be modified later by another plugin . I think I saw a plugin that let you modify these literals.
Well you could redirect, but not required. You only need to send the form to the correct page – for example to the same comment edit dialog was used to write the comment.
Yes, you can’t usepagetop()
nor the inbuild message system. But you could use own message that is shown somewhere alongside the form content, for example. Not as fancy tho.
The problem is that I want to show the messages list after submit. And the message list function is not defined because we are not in the discuss “event”, so the txp_discuss.php (where it is defined) is not included by textpattern. That’s why I include the file here, so I can call discuss_list().
Offline
Re: Improving...
Here is the 0.3 version (first public version) and individual thread: jnm_reply_comments
Offline