ID:168856
 
When you click a link in the browser, is there a way to make it close the window without the player having to click the x (close button) in the corner?
I take it from the lack of responses to this problem that no one can figure out even a simple way to do it? 8P
Try this:
mob/verb/lawlie()
src<<browse("This message will self destruct in 10 seconds.","window=lawlie")
sleep(100)
src<<browse(null,"window=lawlie")
In response to Ol' Yeller
In addition to what Yeller said, make sure the second part of the arg (where the "window=" part was) is exactly the same as the window that you want closed
In response to GhostAnime
So, like, if I had
usr << browse ("some html junk here","window=Allarkis")
and I had links in it using the Topic proc, I could in one of the "conversation" nodes just automatically close it down like this?
area
Adorna
Entered(client)
src << sound('Fates_Adorna.mid',1)
Adorna_Exit
Whittenhague
Entered(client)
usr<<browse("<title>The Portal to Whittenhague</title><font color='black' face=Times New Roman size=3>A description of Whittenhague here<p><b><u>Race Selection Options</u></b><br>Human<br>Wood Elf<p><b><a href=\"?choosewhittenhague\">Enter</b></a><br><b><a href=\"?nevermind\">Never mind.</b></a></font>","window=Allarkis")


client
Topic(href)
if(href=="choosewhittenhague")
usr<<browse(null,"window=Allarkis")
src << sound('Whittenhague.mid',1)
usr.homeland = "Whittenhague"
usr.loc = locate(43,60,3)