2
I would like to know how to override/disregard certain floods placed by users in the input.
I have an input where the person should send me the URL of a site, in case they should send the url as a site.com/image because I have a script that takes the rest of the information.
But it turns out that people input things like site.com/image1.jpg, site.com/image2.jpg site.com/image3.jpg and so the error.
My question is how do I UNDO CERTAIN WORDS IN INPUT like: imagem1.jpg, imagem2.jpg. So the person can send the wrong link but the script would disregard these series of wrong words. Or the scribe could replace and subistituite certain words by a blank space (tmb would resolve)
I tried this script : http://jsfiddle.net/6hxspv14/2/ But in practice it doesn’t work when I click the Submit button excuse the difficulty of expressing myself I’m inciando in programming .
my input code:
<form action="thumbs.php" method="post">
URL da thumb: <input type="text" class="restrict" name="url"><br>
<input type="submit">
</form>
But this script doesn’t have Submit...
– MagicHat
Yes, I say I tested this script in my original code but it didn’t work
– vncalmeida
you want to undo certain words or a word pattern ?
– MagicHat
It’s actually a pattern. 1.jpg 2.jpg 3.jjgp ... up to 30.jpg because users are inserting site/img/1.jpg so the result is site/img/1.jpg.1.jpg because I already got this parameter in php. so I need to override these in input
– vncalmeida
Can you input the input code ? In your question you have a [edit] link edit and put the relevant code, in the control bar you have the {keys}, select all your code and click the keys...
– MagicHat
<form action="Thumbs.php" method="post"> Thumb’s URL: <input type="text" class="restrict" name="url"><br> <input type="Submit"> </form>
– vncalmeida
You can put in your question by editing ?
– MagicHat
ready, put on ;)
– vncalmeida