Forums / Developer / Redirect error after posting a comment

Redirect error after posting a comment

Author Message

Iris Hoekstra - Roscam Abbing

Monday 05 April 2004 6:08:45 am

If you would, please have a look at http://www.elysee.nl/index.php/content/view/full/100

Click on the 'n comments so far' link and try to add a comment. See the error that occurs. I have been trying to figure this one out for I don't know how long but I don't have a clue. Does anyone have any ideas?

I know some things still look a bit daft, especially in IE. I'm still working on it.

Thanks in advance, Iris

Eirik Alfstad Johansen

Wednesday 07 April 2004 1:32:12 am

Hi Iris,

I didn't find any errors, but rather I was brought to the version editing page. If this is what you're referring to as the error, it's probably because you are missing a hidden form field or two in your post-a-comment form.

Sincerely,

Eirik Johansen

Sincerely,

Eirik Alfstad Johansen
http://www.netmaking.no/

Iris Hoekstra - Roscam Abbing

Thursday 08 April 2004 4:46:05 am

Yes, this is exactly what I mean. When testing the site in Opera, you get an error, but in IE, it does what you described.

My form action looks like this:

action={concat("/content/edit/", $object.id, "/", $edit_version)|ezurl}

(Not sure I understand this, but I copied it from the "tscm" tutorial .)

And I have got these two hidden variables:

<input type="hidden" name="MainNodeID" value="{$main_node_id}" />
<input type="hidden" name="RedirectURI" value="{concat("content/view/full/", $object.parent_node.url_alias)|ezurl}" />

And I'm importing these two templates:

{include uri='design:content/edit_validation.tpl'}
{include uri='design:content/edit_attribute.tpl'}

Do I need anything else?

Eirik Alfstad Johansen

Tuesday 13 April 2004 12:09:42 am

Hi Iris,

If I remmeber correctly, there are also some hidden form fields in the edit_placement.tpl template which need to be included. I would recommend that you start with the default edit template and then remove code bit by bit to see which parts that are vital for the edit process to work, and which are not. Sadly, this is not documented anywhere.

Sincerely,

Eirik Johansen

Sincerely,

Eirik Alfstad Johansen
http://www.netmaking.no/

Iris Hoekstra - Roscam Abbing

Thursday 15 April 2004 1:31:56 pm

Thanks, Eirik. Unfortunately edit_placement didn't do the trick. The funny thing is that I also have the blog demosite up and running and there I can add comments without any problems. So I tried to copy everything I could from the templates from that site. I have compared everything about a hundred times but I can't see what's different.

When I look at Apache's access.log, I see that when I add a comment on the blog demosite it does this:
127.0.0.1 - - [15/Apr/2004:19:18:26 +0200] "GET /index.php/elysee/content/view/full/100 HTTP/1.1" 200 13168
127.0.0.1 - - [15/Apr/2004:19:18:42 +0200] "GET /index.php/blog/content/view/full/194 HTTP/1.1" 200 17071
127.0.0.1 - - [15/Apr/2004:19:18:52 +0200] "POST /index.php/blog/content/action HTTP/1.1" 200 8955
127.0.0.1 - - [15/Apr/2004:19:18:53 +0200] "GET /index.php/blog/content/stylesheets/admin.css HTTP/1.1" 200 11843
127.0.0.1 - - [15/Apr/2004:19:18:58 +0200] "POST /index.php/blog/content/edit/302/1 HTTP/1.1" 200 18427
127.0.0.1 - - [15/Apr/2004:19:19:10 +0200] "POST /index.php/blog/content/edit/302/1 HTTP/1.1" 200 12770
127.0.0.1 - - [15/Apr/2004:19:19:12 +0200] "GET /index.php/blog/content/edit/302/stylesheets/admin.css HTTP/1.1" 200 6912
127.0.0.1 - - [15/Apr/2004:19:19:18 +0200] "POST /index.php/blog/blogs/personal/party HTTP/1.1" 200 20423

But when I add a comment on my own site, all it does is this:
127.0.0.1 - - [15/Apr/2004:19:20:10 +0200] "GET /index.php/elysee/active_speakers/test HTTP/1.1" 200 12824
127.0.0.1 - - [15/Apr/2004:19:20:15 +0200] "POST /index.php/elysee/content/action HTTP/1.1" 200 8966
127.0.0.1 - - [15/Apr/2004:19:20:16 +0200] "GET /index.php/elysee/content/stylesheets/admin.css HTTP/1.1" 200 16555
127.0.0.1 - - [15/Apr/2004:19:20:20 +0200] "POST /index.php/elysee/content/edit/327/1 HTTP/1.1" 200 14407

Don't know if that helps, it's really just a different way of describing the same problem. But maybe it'll jog you memory or something.

eZ debug

Timing: Jan 31 2025 04:27:44
Script start
Timing: Jan 31 2025 04:27:44
Module start 'content'
Timing: Jan 31 2025 04:27:44
Module end 'content'
Timing: Jan 31 2025 04:27:44
Script end

Main resources:

Total runtime0.1347 sec
Peak memory usage2,048.0000 KB
Database Queries141

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0052 588.0313180.8281
Module start 'content' 0.00520.0150 768.859498.0078
Module end 'content' 0.02020.1143 866.8672526.2031
Script end 0.1346  1,393.0703 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00312.2719200.0002
Check MTime0.00130.9996200.0001
Mysql Total
Database connection0.00060.482510.0006
Mysqli_queries0.084862.97641410.0006
Looping result0.00100.75371390.0000
Template Total0.114084.710.1140
Template load0.00080.573210.0008
Template processing0.113284.073410.1132
Override
Cache load0.00050.372810.0005
Sytem overhead
Fetch class attribute can translate value0.00060.417210.0006
XML
Image XML parsing0.00030.198210.0003
General
dbfile0.00775.6975200.0004
String conversion0.00000.003730.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0002 secs