post_form

C

Coosa Aa

Dear all,

I'm a newbie and have been looking for a solution regarding the
following issue:
I'm trying to get the results from the page
http://daftarj.spr.gov.my/daftarbi.asp and looking at the source of the
page I have the following information:

<form method="post" name="def" action="daftarbi.asp">
 
C

Coosa Aa

What didn't work is that it's not displaying the results based on the
query as if it didn't submit the id for the hidden field in the input
form!
 
C

Coosa Aa

Coosa said:
What didn't work is that it's not displaying the results based on the
query as if it didn't submit the id for the hidden field in the input
form!

It's not displaying the results; there is a button in the page and when
clicked, a JavaScript function "submitted()" is called. Now the response
is OK, but I get no results as expected; I appreciate you try going to
the link I provided.
Simply I don't know how to call the Javascript function within my Ruby
code.

regards
 
A

Austin Ziegler

It's not displaying the results; there is a button in the page and when
clicked, a JavaScript function "submitted()" is called. Now the response
is OK, but I get no results as expected; I appreciate you try going to
the link I provided.
Simply I don't know how to call the Javascript function within my Ruby
code.

You probably want to ask this on the Rails forum. This is the general
Ruby mailing list, mirrored to ruby-forum.com.

-austin
 
C

Coosa Aa

Coosa said:
It's not displaying the results; there is a button in the page and when
clicked, a JavaScript function "submitted()" is called. Now the response
is OK, but I get no results as expected; I appreciate you try going to
the link I provided.
Simply I don't know how to call the Javascript function within my Ruby
code.

regards

Inside the form (Though it would be helpful):
<INPUT name="txtIC" maxlength="12"><Input type=hidden name="txtSub">
<INPUT type="button" name="Check" value="Check" onclick="submitted()">

I called once in my Ruby Code:
URI.parse('http://daftarj.spr.gov.my/daftarbi.asp'),{"txtSub" =>
"0000059"}
and once:
URI.parse('http://daftarj.spr.gov.my/daftarbi.asp'),{"txtIC" =>
"0000059"}
but it never showed the results either way.
 
A

Austin Ziegler

You probably want to ask this on the Rails forum. This is the general
Ruby mailing list, mirrored to ruby-forum.com.

I was wrong. This is the right place; I just don't know the answer and
I shouldn't post when I'm too busy to read in detail. Sorry, Coosa.

-austin
 
C

Coosa Aa

Austin said:
You probably want to ask this on the Rails forum. This is the general
Ruby mailing list, mirrored to ruby-forum.com.

-austin

I'm not using Rails at all,
The Net::HTTP.post_form is a core Ruby library and i'm just using a
simple Ruby code in a *.rb file
 
P

Pit Capitain

The page says "ELECTION COMISSION OF MALAYSIA, ELECTORS ROLL CHECKING".
Can you tell me what this page is about and what you are trying to do?

Regards,
Pit
 
C

Coosa Aa

Pit said:
The page says "ELECTION COMISSION OF MALAYSIA, ELECTORS ROLL CHECKING".
Can you tell me what this page is about and what you are trying to do?

Regards,
Pit
The problem is solved by modifing the line into:
URI.parse('http://daftarj.spr.gov.my/daftarbi.asp'),{"txtIC" =>
"0000059", "txtSub" => "Submitted"}
The JavaScript function already cleared but I overlooked it!
But for your comment, watch what you write and don't judge and forget
that the page is publically accessible; so I don't post here to get such
comments and I that question of yours doesn't deserve a response!

Regards
 
P

Pit Capitain

Coosa said:
But for your comment, watch what you write and don't judge and forget
that the page is publically accessible; so I don't post here to get such
comments and I that question of yours doesn't deserve a response!

Hi Coosa Aa. Yes, it's a public site. But when I entered the data you've
mentioned, the response looked like personal data to me. Since I don't
know the language spoken in Malaysia, I wasn't sure about that. That's
why I asked you my question. Now, interpreting your answer, I think I
was right that it's possible to get at personal data by entering the
right numbers. If this is not what you're after, I apologize. It seems
you found at least one part of the answer to your question, so I guess I
don't have to show you my solution.

Regards,
Pit
 
C

Coosa Aa

Pit said:
Hi Coosa Aa. Yes, it's a public site. But when I entered the data you've
mentioned, the response looked like personal data to me. Since I don't
know the language spoken in Malaysia, I wasn't sure about that. That's
why I asked you my question. Now, interpreting your answer, I think I
was right that it's possible to get at personal data by entering the
right numbers. If this is not what you're after, I apologize. It seems
you found at least one part of the answer to your question, so I guess I
don't have to show you my solution.

Regards,
Pit

Such childish plays; we're here in a professional forum, so be one. I
even mentioned that I solved it, so don't even try to impress by
mentioning that you have an answer; I don't need it, I have it -
"txtSub" => "Submitted".
 
C

Coosa Aa

Coosa said:
Such childish plays; we're here in a professional forum, so be one. I
even mentioned that I solved it, so don't even try to impress by
mentioning that you have an answer; I don't need it, I have it -
"txtSub" => "Submitted".

[Solved] A kind request for the admins to close the post.
Clearance: the question relates to a part of my "Final Year Project" in
the Multimedia University http://www.mmu.edu.my of the Faculty of IT, to
create an online e-voting system in Malaysia; silly childish questions
attempting to lecture me about morals are useless; any naive person
would obviously see that the page I provided has a "gov" domain and It's
annoying assuming I don't know that! If I'm stupid enough to attempt to
do some thing wrong, I would have obviously written a sample of a normal
page which uses the same pattern; It's the first time in a forum I see
such annoying people like "Pit".
No more replies to this post would be posted from my side.

Regards
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,902
Latest member
Elena68X5

Latest Threads

Top