Load a modal window from a bookmarklet (like the Amazon wishlist bookmarklet)

后端 未结 4 1097
后悔当初
后悔当初 2021-02-02 02:59

I am using a bookmarklet to load an html page which all works great, but, doesn\'t look so hot due to browsers generally being ugly around the outside!

Is there a way t

4条回答
  •  再見小時候
    2021-02-02 03:14

    Upon looking at it more, and inspecting the bookmarklet that appears, here is the overall code structure:

        javascript: (function() { 
           var w = window, 
           l = w.location, 
           d = w.document, 
           s = d.createElement('script'), 
           e = encodeURIComponent, 
           x = 'undefined', 
           u = 'http://www.amazon.co.uk/wishlist/add'; 
           if (typeof s != 'object') l.href = u + '?u=' + e(l) + '&t=' + e(d.title); 
           function g() { 
              if (d.readyState && d.readyState != 'complete') { 
                 setTimeout(g, 200); 
              } else { 
                 // testing if AUWLBook is undefined (AUWL is their global object for it)
                 // If it is, they add the 
    
                                     
                  
提交回复
热议问题