CodeIgniter Forums

Full Version: "curl" makes form submission result in 404
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3

El Forum

[eluser]Bramme[/eluser]
Jup, if I enter test in all the inputs, I just get the "done" echoed on top... I've had weird problems before, but those were almost always my mistake.


I've asked on another forum too and someone there asked if the code was parsed through some sort of eval() function. I said I didn't know and I haven't gotten a reply since then. Could that have anything to do with it?


Edit: the error occurs when curl + additional characters are entered in any of the inputs. If nothing follows "curl", there's (apparently) no problem.

El Forum

[eluser]@li[/eluser]
This might not be relavant at all, but try clearing your cache and try again.

Here's another idea, try changing the names of the fields and see if that makes any difference.

El Forum

[eluser]@li[/eluser]
Note: assuming the controller function still just echoes out one string to keep it simple so we can trace down the problem. Looks like it only occurs if string length is > 4. Would be interesting to see why.

El Forum

[eluser]Bramme[/eluser]
[quote author="@li" date="1223768152"]Note: assuming the controller function still just echoes out one string to keep it simple so we can trace down the problem. Looks like it only occurs if string length is > 4. Would be interesting to see why.[/quote]that is not the case, I can post stuff with strlen > 500 if I'd want, it just can't contain the word "curl" with characters after it.

And I'm not sure if the cache is the problem seeing as it's happening here and on another computer in another country.

And the field names apparently don't matter either. I've entered "curl " in all the fields of the form...

El Forum

[eluser]ray73864[/eluser]
seeing as how 'curl' is a program allowing you to do stuff with remote websites, perhaps codeigniter is trying to run the program?

El Forum

[eluser]Bramme[/eluser]
wouldn't know... I haven't got this bug with another website and it's the same CI installation... The form's got a file upload though. Could that matter?

El Forum

[eluser]@li[/eluser]
I suggest this bramme.

Remove all fields from your form (keep a backup) and start adding them one at a time, starting from the simplest text field. See if the error is reproduced with that field. If not, keep adding more with the most complex fields at the end until you can reproduce the error. Then post here and let us know.

El Forum

[eluser]Bramme[/eluser]
Code:
<form action="<?=$this->uri->uri_string()?>" method="post">
<div class="left">
<p>
    <label for="title">title<br />
    &lt;input type="text" name="title" id="title" value="&lt;?=$this-&gt;validation->title?&gt;" />
    </label>

</p>
</div>
<p style="clear: both">
    &lt;input type="submit" name="submNewTutorial" value="Submit" /&gt;
</p>
&lt;/form&gt;
even this causes the error. I'll try separating all the fields.

El Forum

[eluser]@li[/eluser]
Hey man,

This might not be causing this but try replacing
Code:
&lt;?=$this->uri->uri_string()?&gt;

with direct URL to the script e.g
Code:
&lt;?=form_open('your/site/admin/page');?&gt;

Also you did mention that this was working on a different server, right? There might be something in your server configuration which causes 'curl' based submissions to fuck up. We can look into that if this doesn't work.

El Forum

[eluser]Bramme[/eluser]
[quote author="@li" date="1223819191"]Hey man,

This might not be causing this but try replacing
Code:
&lt;?=$this->uri->uri_string()?&gt;

with direct URL to the script e.g
Code:
&lt;?=form_open('your/site/admin/page');?&gt;

Also you did mention that this was working on a different server, right? There might be something in your server configuration which causes 'curl' based submissions to fuck up. We can look into that if this doesn't work.[/quote]

Tried that now. Doesn't work Sad

I haven't tried putting this on a different server. Did I say that anywhere? must've made a mistake. I could try putting it on localhost...
Pages: 1 2 3