How to make applescript open a new safari window with a specific name?

tell application "Safari"
  activate
  make new document at end of every document with properties {name:"MY-NAME", URL:"http://www.google.com"}
end tell
Run this script and see if you can figure out why the NAME of the window is still "Google".
The dictionary  shows several different NAMEs for windows, documents and tabs and only tabs are R/O.
This doesn't do anything either:
tell application "Safari"
  activate
  make new document at end of every document with properties {name:"MY-NAME", URL:"http://www.google.com"}
  set the name of window 1 to "TEST"
end tell

The title of the window is provided by the page source.
You can override it (once loaded) with, e.g,
     do javascript "document.title='MY-NAME'" in document 1
If you had a blank Safari page (i.e. not Top Sites which does contain source data), you should be able to change the window title with
     set name of document 1 to "MY-NAME"

Similar Messages

  • How to make nikeplus open in new Safari/ML?

    Hi, I cannot log in to http://nikeplus.nike.com/plus/ with Safari (the page itself loads but when pressing "Log in" it just spins forever.
    It works just fine with e.g. Google Chrome. Does anyone else notice same behavior? Is there workaround? Thanks

    Check Safari > Preferences > Advanced
    Where you see:  Style sheet
    Click:  None Selected   where you see Style sheet:
    If that's not the issue, try deleting the cache.db.
    Quit Safari. Now open the Finder. From the Finder menu bar top of your screen click Go > Go to Folder
    Type this exactly as you see it here:   ~/Library/Caches/com.apple.Safari/Cache.db
    Click Go then move the Cache.db file to the Trash.
    Relaunch Safari to test.
    If that didn't help, back to Safari > Preferences > Security
    Deselect:  Enable plug-ins
    Quit then relaunch Safari to test.
    If that helped, there's a third party plugin installed that's preventing the drop down login.
    Troubleshooting help here > Safari: Unsupported third-party add-ons may cause Safari to unexpectedly quit or have performance issues

  • Unwanted urls load every time I open a new Safari window.  How do I stop this?  Is this spyware?

    I have 4 unwanted urls that load every time I open a new Safari window.  How do I eliminate this?  Are these spyware or other malicious code?
    I have trashed cache.db, history.plist and LastSession.plist and these did not solve the problem.  Thanks for any help I can get.

    Michael DiPirro wrote:
    b noir,
    That looks like where they are.  How did this toolbar appear?  Can I remove the entire toolbar?
    Mike
    I'm having trouble keeping up with this topic ... every time I've finished a post, there's three or four new replies showing up and the troubleshoot has moved on.
    The toolbars can be (silently) installed by a number of different packages/websites, although I fear I'm well behind the times on what packages/websites are most commonly installing them for folks nowadays. There's a lot of variations about, as it's a platform rather than a specific application:
    http://www.conduit.com/Toolbar/Benefits.aspx
    I'll defer to Carolyn on the state-of-the-art when it comes to removing the toolbars.

  • Every time I open a new safari window, an ad pops up. how do I get rid of it?

    every time I open a new safari window, an ad pops up. how do I get rid of it?

    Safari ▹ Preferences... ▹ General ▹ New windows open with: Empty Page

  • I have tried to set my homepage to a specific website. However, whenever I open a new Safari window, it always returns to the last page I was at before I closed Safari. Any ideas? I did this was Safari preferences, open new window to homepage...

    I have tried to set my homepage to a specific website. However, whenever I open a new Safari window, it always returns to the last page I was at before I closed Safari. Any ideas? I did this under Safari preferences, open new window to homepage...

    Safari is opening using the resume feature. To disable that, quit Safari using Command+Option+Q or Hold Option when choosing the menu item Safari>Quit.

  • Opening a new Safari window cases Safari to hang

    I just updated to Yosemite 10.10.1. Since doing so I can no longer open an additional safari window from within safari.   Safari hangs.  The only thing I can do is to drag tab to the desktop to create a new window. 

    Please read this whole message before doing anything.
    This procedure is a test, not a solution. Don’t be disappointed when you find that nothing has changed after you complete it.
    Step 1
    The purpose of this step is to determine whether the problem is localized to your user account.
    Enable guest logins* and log in as Guest. Don't use the Safari-only “Guest User” login created by “Find My Mac.”
    While logged in as Guest, you won’t have access to any of your documents or settings. Applications will behave as if you were running them for the first time. Don’t be alarmed by this behavior; it’s normal. If you need any passwords or other personal data in order to complete the test, memorize, print, or write them down before you begin.
    Test while logged in as Guest. Same problem?
    After testing, log out of the guest account and, in your own account, disable it if you wish. Any files you created in the guest account will be deleted automatically when you log out of it.
    *Note: If you’ve activated “Find My Mac” or FileVault, then you can’t enable the Guest account. The “Guest User” login created by “Find My Mac” is not the same. Create a new account in which to test, and delete it, including its home folder, after testing.
    Step 2
    The purpose of this step is to determine whether the problem is caused by third-party system modifications that load automatically at startup or login, by a peripheral device, by a font conflict, or by corruption of the file system or of certain system caches.
    Please take this step regardless of the results of Step 1.
    Disconnect all wired peripherals except those needed for the test, and remove all aftermarket expansion cards, if applicable. Start up in safe mode and log in to the account with the problem. You must hold down the shift key twice: once when you turn on the computer, and again when you log in.
    Note: If FileVault is enabled in OS X 10.9 or earlier, or if a firmware password is set, or if the startup volume is a software RAID, you can’t do this. Ask for further instructions.
    Safe mode is much slower to start up and run than normal, with limited graphics performance, and some things won’t work at all, including sound output and Wi-Fi on certain models. The next normal startup may also be somewhat slow.
    The login screen appears even if you usually log in automatically. You must know your login password in order to log in. If you’ve forgotten the password, you will need to reset it before you begin.
    Test while in safe mode. Same problem?
    After testing, restart as usual (not in safe mode) and verify that you still have the problem. Post the results of Steps 1 and 2.

  • Opening a new Safari window

    Last year I downloaded a program that had a green icon that looks likes a round speedometer with "SS" on it. It is labeled "New Safari Window". When you click this, a new safari window opens. Can anyone tell me where to find this download? I have it on my imac but when I tried to transfer it to my macbook, it won't work there. Thanks

    Chris --
    Version Tracker is a great source of info like this.
    I went there and searched for "Safari".
    Here is the URL for what they came up with:
    Here

  • Opening/focusing new/existing window with refreshed data

    hi ,
    I want to open the results in a new browser window with current requested data as soon as I click on a button from a jsp.I mean as soon as I click on a button if the new window is already opened then the opened window should be get focused with refreshed current data, if the new browser window is not already opened then clicking on button from jsp should open a new window with refreshed data.
    Following both ways are not working proper, could you tell me whts wrong with it..?
    javascript functions:
    function winOpen(statusVal)
    var resultsUrl = "http://.........";
    var fullURL= resultsUrl+"Status="+statusVal;
    var lastOpened = null
         if ( lastOpened != null ) {
              lastOpened.close();
              lastOpened = null;
    lastOpened =window.open(fullURL, null)
    lastOpened.focus();
    with this code new window is opening but if I minimize that new window and if I click on a button jsp with new querry values, the same opened window is getting focused but not with new results in that window. I.e results in window are not getting refreshed ....
    2.
    with the following code every time it opens the new new windows( irrespective of already opened window) with new requested data.
    function winOpen(statusVal)
    var resultsUrl = "http://.........";
    Openedwindow=window.open(resultsUrl+"Status="+statusVal;
    Openedwindow.focus();

    Can u let me know how you solved this.
    Thanks in advance

  • How to make link open in new TAB and not new window

    Mac users can do the following...
    http://www.switchingtomac.com/tutorials/how-to-force-safari-4-to-open-links-in-a -new-tab-instead-of-a-new-window/
    how can this be done for WIndows users?
    Using Safari 4.0

    I'm not totally sure what you mean, because unless you are talking about not having to right-click a link first, that is prasisly what I do. the link you provided I just right clicked it & clicked on "open in new tab" ,& that's what it did.
    - But now because that was so easy to answer, I can only assume you mean not actually having-to right-click a link to open it up in a new tab. ,hope this helped.

  • How to make links open in new window

    Is it Javascript? How do you make links open in a new
    window.. what's the code and where do you put it, how do you end
    it?

    Target box (below link box0) to "_blank"
    "BenMan 88" <[email protected]> wrote in
    message
    news:e7v4it$jfj$[email protected]..
    > Sorry, this is totally unnecessary and I hope it doesn't
    irritate anyone
    > but thank-you this posting helped me very much.
    >
    >

  • How to make applescript open a program

    I am new to Applescript. How can I use it to open a program

    Simple:
    <pre class=command>tell application "Name of application" to activate</pre>
    This will bring it to the front, launching it if it isn't already running.
    If you just want it to launch without coming frontmost, change 'activate' to 'launch'.

  • How to make applescript open more than one program at once?

    Hi! I made the code below to use together with another 2 codes. One that mounts a samba share and another that runs rsync with specific parameters. The script below runs after rsync complete its task.
    The 3 codes help me to test my HTML/CSS/PHP/Javascript code changes.
    This code works but I have to repeat it to each browser/app I want and a 10 lines script becomes 40 lines (Google
    Chrome, Firefox, Opera and Safari). Is there a more elegant way to do that? I've tried to use an array/list but didn't work.
    if application "Safari" is running then
        tell application "Safari"
            activate
        end tell
        tell application "System Events"
            tell process "Safari"
                keystroke "r" using {command down}
            end tell
        end tell
    end if

    Nathan Greenstein already answered in AskDifferent: http://apple.stackexchange.com/questions/54595/applescript-array-of-applications /54598#54598
    Quoting him:
    set browsers to {"Google Chrome", "Firefox", "Opera", "Safari"}
    repeat with browser in browsers
        if application browser is running then
            tell application browser
                activate
            end tell
            tell application "System Events"
                tell process browser
                    keystroke "r" using {command down}
                end tell
            end tell
        end if
    end repeat

  • I can't open a new safari window by clicking the icon on the bottom

    As above, I want to open multiple window by clicking the icon on the bottom but it does not work.
    Is there somebody who helps this problem?
    Thanks.

    I want to open multiple window by clicking the icon on the bottom but it does not work.
    You can only open one Safari window at a time from the Safari icon in the Dock but you can save open Safari windows by clicking on the orange radio button top left in the Safari window. That will save that page to the right of the insertion mark on the Dock next to the Trash for easy access.

  • Using a text link to open a new browser window to a specific size

    i can figure out how to make a link open up a new window
    (_parent, _top, etc.), but how do i make the window a specific
    size?
    thanks,

    Hi joeq ,
    We don't need to change the html page title. I tested the
    same code ('undefned') in html/javascript, but not with flash.
    Use the same script in html/javascript and test it.
    If it works fine, then create a javascript function in your
    parent html.
    Then call the function from flash, it will be fine.
    I tested the same code with IE, Netscape, Firefox(linux),
    also mac-safari.
    Regards,
    Sankarapandian T.
    [email protected]
    Chennai, India.

  • Drop Down Menu - 3rd Level iView open in new external Window with parameter

    Hello Community,
    we have the following problem: We have created some drop down menu for the portal navigation. Some iViews we are going to open in new Window. Therefore the iViews are getting some parameters like: menubar=no, toolbar=no, resizable=yes, status yes....and so one....And also the iView has fixed height and width.
    Now when we are going to open the iview in the second level position, everything is working fine and the window functions are also used.
    When we change the position of the iview from an second level position to an third level position, and we want to open the iview from the drop down menu, the window functions and the size is not used.
    Can some one help? I have attached the JSP Code:

    [JSP File|http://www.megaupload.com/?d=R7YLTTKX]

Maybe you are looking for

  • BI 7.0: Issue with Hierarchy for infoObject OPROD_HIER

    Hi Gurus, I have activated the Hierarchy datasource  0PROD_HIER_LPRH_HIER in ECC, tested  with transaction RSA3 (456 node IDs) and replicated to BW. In BW, the datasource has been assigned to the infosource  OPROD_HIER ; when I have created the infop

  • Valuation - why accounts in LC???

    Hi all, why is the system valuating accounts maintained in local currency to which some posting in foreign currency were made? I thought only accounts in foreign currency are valuated... Thanks, Zbynek

  • LOC and OD

    Hi Friends, How to Implement Letter Of Credit And Over Draft Functionality in Oracle Apps? Thanks, Cnubandi

  • Unexpected loading and unloading of BusinessObjects DLL's slows down app.

    Hi all, I have a dev laptop, and a client tabletpc. In my application I preload a report to get a faster initial view of the report I'm using. I noticed very slow preloading on my clientmachine. This doesn't happen on my dev. machine. I did some obse

  • How to learn Webdynpro online

    Hello, I would like to learn webdynpro online. Like is there any link through which I can learn. Like is there any possibility to download and install a component and start doing the programming. Please help me providing some relevant information. th