HelpFacebook

Posts 1–9 of 9 · Page 1 of 1
Facebook
Heey , im trying to make small app with web browser for fb (just for fun but when i write to navigate : m.facebook.com
i cant get full mobile version ?
There is a 'setting' called UserAgent, basically it's just a unique string that 'represents' which browser software (firefox, iexplorer, etc) is being used. The 'browser' sends this info to the server each time it requests a page. The web-server can choose to send a different version (usually file) of the page, based on the useragent.

Idk how, I assume you're using the built in iexplorer component? google "Set UserAgent in iexplorer vb.net" (or whatever the component name is) - the useragentstring you want probably has "Mobile" in the name : D

edit: I did the search.
First result: http://www.vbforums.com/showthread.p...owser1-control
2nd post down..
user 'TheKill3r' says
"
Code:
WebBrowser1.Navigate "http://www.yoursite.com", , , , "User-Agent: Here Put The User Agent"
"

but you have to supply the argument every time you call the function, which is maybe annoying (?), apparently there is a registry setting you can mess with related to user-agent. ?

-and a list of 'mobile' browser user-agent string constants.
http://www.useragentstring.com/pages...20Browserlist/
.
ex. "Mozilla/5.0 (Linux; U; Android 4.0.3; ko-kr; LG-L160L Build/IML74K) AppleWebkit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30"
.
and one for a non-mobile browser (ie. pc?)
"Mozilla/5.0 (Windows NT 6.2; WOW64; rv:16.0.1) Gecko/20121011 Firefox/16.0.1"

I'm not sure on the format/syntax. Another google : )
Quote Originally Posted by abuckau907 View Post
There is a 'setting' called UserAgent, basically it's just a unique string that 'represents' which browser software (firefox, iexplorer, etc) is being used. The 'browser' sends this info to the server each time it requests a page. The web-server can choose to send a different version (usually file) of the page, based on the useragent.

Idk how, I assume you're using the built in iexplorer component? google "Set UserAgent in iexplorer vb.net" (or whatever the component name is) - the useragentstring you want probably has "Mobile" in the name : D

edit: I did the search.
First result: How to change UserAgent of WebBrowser1 control?-VBForums
2nd post down..
user 'TheKill3r' says
"
Code:
WebBrowser1.Navigate "http://www.yoursite.com", , , , "User-Agent: Here Put The User Agent"
"

but you have to supply the argument every time you call the function, which is maybe annoying (?), apparently there is a registry setting you can mess with related to user-agent. ?

-and a list of 'mobile' browser user-agent string constants.
UserAgentString.com - List of Mobile Browser User Agent Strings
.
ex. "Mozilla/5.0 (Linux; U; Android 4.0.3; ko-kr; LG-L160L Build/IML74K) AppleWebkit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30"
.
and one for a non-mobile browser (ie. pc?)
"Mozilla/5.0 (Windows NT 6.2; WOW64; rv:16.0.1) Gecko/20121011 Firefox/16.0.1"

I'm not sure on the format/syntax. Another google : )
thanks , i'll try it tomorrow


and why is this three times ,,, ? i removed 'em now its only one

edit: nope , it opens site in internet explorer nad webbrowser1 is empty
haha no, the commas are there to show you 'there are more arguments'. idk what they are :/ but i basically gave you the answer....it'll be something like...

Type in WebBrowser1. (see the dot) and Intellisense will show you all of it's members (variables and functions) and their over-loads.. opening msvs to take a ss, brb :/

edit:


^^maybe the parameter "additionalHeaders" contains the useragent? Read up : )

---------- Post added at 07:32 PM ---------- Previous post was at 07:17 PM ----------

Your sig. says you've made an injector..but you didn't know about the intellisense/overloading/comma thing. Interesting.
Quote Originally Posted by abuckau907 View Post
haha no, the commas are there to show you 'there are more arguments'. idk what they are :/ but i basically gave you the answer....it'll be something like...

Type in WebBrowser1. (see the dot) and Intellisense will show you all of it's members (variables and functions) and their over-loads.. opening msvs to take a ss, brb :/

edit:


^^maybe the parameter "additionalHeaders" contains the useragent? Read up : )

---------- Post added at 07:32 PM ---------- Previous post was at 07:17 PM ----------

Your sig. says you've made an injector..but you didn't know about the intellisense/overloading/comma thing. Interesting.
nice c# pic but i know how to use commas (i didnt know why u copied 'em ...
i gave me answer but it opens facebook in internet explorer
you people need to start using APIs/SDKs that are offered to you
Quote Originally Posted by SAMCRO View Post
Welcome to Facebook -- is what I use in my VB Apps.
finally , thank you
Posts 1–9 of 9 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Talk with us