473,387 Members | 1,691 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

The meaning of form action of form "r/sx/*-http://somehow/somescript"

When processing HTML-files for various purposes, I run into a strange
form action definition looking like

"r/sx/*-http://somehow/somescript"

In particular, the Yahoo search form uses a form action attribute which
looks like this.

What's the meaning of the "r/sx/*-"-prefix?

--
Aatu Koskensilta (aa**************@xortec.fi)

"Wovon man nicht sprechen kann, daruber muss man schweigen"
- Ludwig Wittgenstein, Tractatus Logico-Philosophicus

Jul 20 '05 #1
4 3900
Aatu Koskensilta wrote:
When processing HTML-files for various purposes, I run into a strange
form action definition looking like

"r/sx/*-http://somehow/somescript"

In particular, the Yahoo search form uses a form action attribute which
looks like this.

What's the meaning of the "r/sx/*-"-prefix?


To go to ./r/sx/*- (which IIRC is some form of redirect script)

--
David Dorward http://dorward.me.uk/
Jul 20 '05 #2
David Dorward wrote:
Aatu Koskensilta wrote:

When processing HTML-files for various purposes, I run into a strange
form action definition looking like

"r/sx/*-http://somehow/somescript"

In particular, the Yahoo search form uses a form action attribute which
looks like this.

What's the meaning of the "r/sx/*-"-prefix?

To go to ./r/sx/*- (which IIRC is some form of redirect script)


Ah. That seems sensible. Are there syntactical restrictions on the form
the scheme component of an URI can take? Otherwise "r/sx/*-http" could
name a (unregistered) scheme. I'll go check the relevant RFCs and file a
bug report on PHPs parse_url()-function (it seems to mistakenly think
"r/sx/*-http" is a scheme) in case the scheme is e.g. restricted to
consist only of alphabetical characters or something on the lines.

--
Aatu Koskensilta (aa**************@xortec.fi)

"Wovon man nicht sprechen kann, daruber muss man schweigen"
- Ludwig Wittgenstein, Tractatus Logico-Philosophicus

Jul 20 '05 #3
David Dorward wrote:
Aatu Koskensilta wrote:

Ah. That seems sensible. Are there syntactical restrictions on the form
the scheme component of an URI can take? Otherwise "r/sx/*-http" could
name a (unregistered) scheme.

===== rfc 2396 ==========

3. URI Syntactic Components

The URI syntax is dependent upon the scheme. In general, absolute
URI are written as follows:

<scheme>:<scheme-specific-part>

An absolute URI contains the name of the scheme being used (<scheme>)
followed by a colon (":") and then a string (the <scheme-specific-
part>) whose interpretation depends on the scheme.

=========================

http://www.ietf.org/rfc/rfc2396.txt

In URIs, the scheme is indicated by it ending in a colon. I believe the
colon in the above URI should be encoded as %3A


Probably yes. The RFC specifies the following grammar for <scheme>

<scheme> := alpha *( alpha | digit | "+" | "-" | "." )

I've added a check to see that a potential scheme conforms to this
grammar to my processing scripts.

Another very strange thing about the Yahoo web site is that as a result
of submitting a search query we get a 320 Found reply with the Location
header field having value

http://search/?p=searchstring&sub=Search&fr=fp-top

or something on the lines. I don't think this conforms to the HTTP/1.1
specification, which says that the Location-header field should contain
an absolute URL. Apparently browsers can guess what Yahoo means by this
but I'm at loss.

--
Aatu Koskensilta (aa**************@xortec.fi)

"Wovon man nicht sprechen kann, daruber muss man schweigen"
- Ludwig Wittgenstein, Tractatus Logico-Philosophicus

Jul 20 '05 #4
Aatu Koskensilta wrote:
David Dorward wrote:
Aatu Koskensilta wrote:

Ah. That seems sensible. Are there syntactical restrictions on the form
the scheme component of an URI can take? Otherwise "r/sx/*-http" could
name a (unregistered) scheme.


===== rfc 2396 ==========

3. URI Syntactic Components

The URI syntax is dependent upon the scheme. In general, absolute
URI are written as follows:

<scheme>:<scheme-specific-part>

An absolute URI contains the name of the scheme being used (<scheme>)
followed by a colon (":") and then a string (the <scheme-specific-
part>) whose interpretation depends on the scheme.

=========================

http://www.ietf.org/rfc/rfc2396.txt

In URIs, the scheme is indicated by it ending in a colon. I believe the
colon in the above URI should be encoded as %3A

Probably yes. The RFC specifies the following grammar for <scheme>

<scheme> := alpha *( alpha | digit | "+" | "-" | "." )

I've added a check to see that a potential scheme conforms to this
grammar to my processing scripts.

Another very strange thing about the Yahoo web site is that as a result
of submitting a search query we get a 320 Found reply with the Location
header field having value

http://search/?p=searchstring&sub=Search&fr=fp-top

or something on the lines. I don't think this conforms to the HTTP/1.1
specification, which says that the Location-header field should contain
an absolute URL. Apparently browsers can guess what Yahoo means by this
but I'm at loss.


Uhhuh. Just ignore this last bit of rambling. It turned out to be an
error on my part.

--
Aatu Koskensilta (aa**************@xortec.fi)

"Wovon man nicht sprechen kann, daruber muss man schweigen"
- Ludwig Wittgenstein, Tractatus Logico-Philosophicus

Jul 20 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Sylvie Stone | last post by:
Hi group - I have an html form for that uses username and password to login to a specific area of the website. The "area" the user wants to go to is based on a pull down menu. Becasue the...
3
by: Pavils Jurjans | last post by:
Hello, I have bumped upon this problem: I do some client-side form processing with JavaScript, and for this I loop over all the forms in the document. In order to identify them, I read their...
1
by: tnhoe | last post by:
Hi, <Form method='post' action="next.htm?btn="+"this.myform.myobj.value"> What is the correct syntax for above ? Regards Hoe
11
by: Pete Wilson | last post by:
Hi folks -- The page at http://www.pwilson.net/submit-demo.html will not validate. The validator at http://validator.w3.org tells me I can't have an input inside a form. Would some kind...
1
by: feng | last post by:
Hi, I know this might not be a question for this group but I would give it a try anyway as I couldn't find a better group for my question. I have noticed that there are a lot of articles out...
7
by: Rich | last post by:
Hi, I was experimenting with some basic sample asp code but can't get it to work correctly: this is bgselector.asp which works OK - you add the name of a basic color like blue, green, yellow...
0
by: bolinc | last post by:
Can someone tell me why this isn't working? <Script language="JavaScript"><!--// var bJavaEnabled = Boolean(clientInformation.javaEnabled()); if (bJavaEnabled){ document.write('<form...
8
by: webandwe | last post by:
Hi, I have to radio buttons and depending on the selection it must eighter insert step2.php or insert.php in the action part of the form. Now it's just going to steo2.php I also tried elseif...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.