I assume you have the November 2009 third edition.
I assume you have the November 2009 third edition.
Hi there c1lonewolf,
Well, this is a very good example of the "inadequate coding skills" to which I alluded.
Like with IE and probably every other browser, you create a 400x400 div and position a 1 pixel object at 0,0 and one at 400,400 and you see both objects.
However, if you you add a solid 1px border to it you lose the 400,400 object.
It's hidden under the border.
So in actuality your container has to be 401x401 because the morons can't add a single pixel to the x & y border controls.
Give me a break!
When positioning an object, the point of reference is the top left of that object when using top and left.
However, when using bottom and right, the point of reference is the bottom right.
Therefore to position a 1px square object to the bottom right of a 400px square div element requires either...
...or...Code:element { top:399px; left:399px; }
Of course, novice coders much prefer to berate browsers than admit to their own shortcomings.Code:element { bottom:0; right:0; }
You may now take that break.
coothead
hi kool dude,
i've tried it with the window opened using window.open() method and the resizeTo() method works but not on the window itself. but with this resizeTo() method it gave me an idea to make a script so that i can resize the safari window in different standard sizes i want, just like the web developer add-on on firefox does. i hope that the web developer add-on would also be ported on safari for mac. anyway thank you so much kool dude for your time and knowledge.
hi mmi,
yes, you're right. this is the book i'm reading right now. because this is the only book i know that i can really understand as a beginner and really don't know anything about javascript. i just based it on the reviews of this book on the amazon that why this is the i picked.
do you have something in mind that's similar to john pollock's book that's new? i checked the books website and his third edition i think is the last he did.
Hi there orrange23,
Sorry, but I missed your post with the above question....
You said that I should concentrate more on learning customer friendly javascript.
Do you mind sharing what this is?
...
Still, better late than never.
The following links may possibly provide a little enlightenment...
- http://en.wikipedia.org/wiki/Unobtrusive_JavaScript
- http://icant.co.uk/articles/seven-ru...ve-javascript/
- http://www.onlinetools.org/articles/.../chapter1.html
coothead
OK, here is some additional information I found on this:
The main browser window has security restrictions that prevent resizing due to a lot of misuse by some web sites over time. Thus, almost all browsers disallow resizing the main window (IE may allow this on your computer, where some restrictions are lifted, but does not allow it over the Web. Safari may be doing something similar here, someone may be able to test that out).
So, resizing the main window, in general, is no longer allowed.
When using window.open(), most browsers allow the resize of the new window.
- Modern browsers only allow new windows to be opened by a user click or key press in most cases.
- IE7+: Pop-up window resizing may not be allowed, depends on settings. IE 8 on XP allowed me to resize a new window offline. Other versions/situations would need to be tested.
- FF and Chrome allowed the resize offline, would need to test online.
- Opera only opens the window as a new tab in the main browser window. Thus, it won't allow a resize at all.
Hope this sheds a little more light on this particular method!
hi guys,
thank you very very very much for all your help. with the links and the knowledge about this method. now i'm on the math object chapter. good luck to me because i stink at math that's the reason i got into design. by the way john if you ever need a volunteer in making your next book i'll be glad to help. again thank you guys off to reading chapter 12 i hope this math object is as easy as 123![]()
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks