Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Display window? 1

Status
Not open for further replies.

august

MIS
Joined
Aug 24, 2000
Messages
150
Location
PH
How can i display my window with my own size and also without scrollbar,navigator and so on it is possible?

Thanks in advance THANKZ!
August
agencisa@yahoo.com
 
You can try opening a new window from javasript: there are many ways of calling them, this is one of them:

in the <head> section put this:

<script>
function openwindow(file,name,prefs) {
var wind = window.open(file,name,prefs);
}
</script>


And in the <body> section this:


<a href=&quot;javascript:openwindow('somefile.html','name1','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=auto,resizable=no,copyhistory=no,width=550,height=350')&quot;>Open first file</a>

<a href=&quot;javascript:openwindow('somefile.html','name2','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=auto,resizable=no,copyhistory=no,width=550,height=350')&quot;>Open second file</a>


Now everytime you call this function, u change the name of the HTML file and the 'name' property...
Hope this helps... I have not failed; I merely found 100,000 different ways of not succeding...
 
Thanks a lot GUJUmodel! THANKZ!
August
agencisa@yahoo.com
 
Is it possible to make a page open without scroll bars if it is not linked from within one's own site...ie such as a home page?

Thanks.

Nick
 
ssidetv, can u be more specific?? You want 2 open a page from you're hompage thats on an outside URL?? And you want it to be without scrollbars?? Is that right?? If it is, then it is possiable, but why?? If you don't have the scroll bars then some information might be left out... I have not failed; I merely found 100,000 different ways of not succeding...
 
hey august if my post was helpful vote for me as tek-master...:P thanx... I have not failed; I merely found 100,000 different ways of not succeding...
 
GUJU - no, what I am seeking is to have a home page open without scroll bars. So, for instance, someone clicked on a link to my home page, it would open without scroll bars....can I control that?

Thanx
N
 
ssidetv, are the scroll-bars on the left-side of the screen or the bottom??
There might be a way to do this. It might be sort of out of the way tactic, but try this:

1...Create a index page that will redirect you're users to the homepage. (an auto-redirect can be uselful here)
2...The index page now can be controlled because you'd call the index page from the javascript openwindow function described above...

i'm in class now, give me till tomm. to create a 'dummy' script for you, ok?? then if you like the results, all you would do is plug in the relevant information. ok?? I have not failed; I merely found 100,000 different ways of not succeding...
 
ssidetv, OK, try this:


<head>
<title>Untitled Document</title>
<meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=iso-8859-1&quot;>
<script language=&quot;Javascript&quot;>
function openwindow(file,name,prefs) {
var wind = window.open(file,name,prefs);
}

var newURL = &quot;javascript:openwindow('index.html','window','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=auto,resizable=no,copyhistory=no,width=500,height=500')&quot;
var rate = 1000
function directpage() {
location = newURL
}
setTimeout(&quot;directpage()&quot;, rate);
</script>
</head>





This what the code does:
1) You have two functions in the <head> tags; function openwindow and directpage.

2) You know what the openwindow functions (I explained it on the top of this post)

3) The directpage function will redirect the users from one page to another. Since you wanted to control the scrollbars and other properties in the homepage.html file, this is what you will have to do...create a page and call it 'homepage.html' and on this page have the script I posted here, then create another page called 'index.html'...this script will auto-direct and load the 'index.html' inside of a new window that you control the properties of...understand??
NOTE: the 'index.html' will open in a new window so make sure on the 'homepage.html' you indicate that.
If you have any questions, just ask... I have not failed; I merely found 100,000 different ways of not succeding...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top