I think I am going to go insane! Which web technology to use...
Hi,
For some time now, I've been tyring to figure out what to learn in terms of developing web sites with a view to producing stuff increasingly dB-driven. Working for a large (read: 76,000+ employees) company, I've taken some breif glimpses at PHP and liked what I saw, but not being a 'natural' coder have not had the time needed to invest in learning it all ...and the Co. is firmly in the Microsoft court all-told.
I've used straight HTML ok, but found a lot of the stuff I'm looking to do would be really high-maintenance ...far better-suited to storing data in a dB and pulling it back out, rather than editing static code, even with templates.
I've had some indirect exposure to J2EE through a Hyperion product but my company's chosen direction is as stated M/S based, and most recently .NET. Our new global intranet portal is going to be based
around .NET and Sharepoint for instance so I've been trying to lean towards technology that might come in useful work-wise at some point.
Anyway, I've just started to look at .NET with Web-Matrix with these factors in mind, and already I'm getting frustrated.
It seems that with every technology I look at, there isn't one that 'does it all' or has consistency across the main browser platforms. At the most simplistic level:
Quote:
M/S .NET Example under IE:
<p>
<input name="TextBox1" type="text" value="hi there u" id="TextBox1" />
</p>
<p>
<input type="submit" name="Button1" value="Click Me!" id="Button1" style="color:#000000;background-color:#CCCCCC;border-color:#000000;Z-INDEX: 109; LEFT: 88px; TOP: 108px" />
</p>
Quote:
M/S .NET Example under Firefox:
<p>
<input name="TextBox1" type="text" value="hi" id="TextBox1" />
</p>
<p>
<input type="submit" name="Button1" value="Click Me!" id="Button1" style="Z-INDEX: 109; LEFT: 88px; TOP: 108px" />
</p>
Is it just me, or is it still a case of there being (almost) nothing that you can expect consistency in? Do you still have to write code for multiple possible configurations etc? I mean, Mozilla and its variants have a significant proportion of the market now, and I just think it's unreasonable to try to dictate to a (general) user what browser they should and shouldn't use ...or for a site to fall-over when the user doesn't employ a specific browser???
This is driving me nuts, I've had it in the above examples through to things like Firefox handling transparency in images and IE not, HTML element handling (like DIVs etc) and I'm just wondering ...Is there not any one technology out there that I can learn which will make like easier? I work 40-60hrs a week in front of a PC ...don't have time and energy to learn this stuff in my 'spare' time and spend half that time finding work-arounds and fixes to compatibility issues.
Thanks for letting me Rant! hoping somebody's found this holy grail.
Another thing with .NET too...
Question:What is the point ...other than 'being Microsoft' of writing whole bunches of page code in VB.NET only to view source on your code, and see the browser has turned it all into JavaScript?
e.g. .NET code snippett:
Quote:
Dim gv_path as string
Dim gv_slidesnames(5) As String
Dim gv_currentslide as Integer
' Page_Load Event Handler Subroutine processed each time page loads
Sub Page_Load()
gv_path = "images/marble/"
gv_slidesnames(0) = "img00.png"
gv_slidesnames(1) = "img01.jpeg"
gv_slidesnames(2) = "img02.png"
gv_slidesnames(3) = "img03.png"
gv_slidesnames(4) = "img04.png"
gv_slidesnames(5) = "img05.png"
' Replaced code to handle viewstate
' img_slide.ImageUrl = gv_path & gv_slidesnames(0)
If IsPostBack = True then
gv_currentslide = ViewState("gv_currentslide")
Else
gv_currentslide = 0
Viewstate("gv_currentslide") = gv_currentslide
img_slide.ImageUrl = gv_path & gv_slidesnames(gv_currentslide)
End If
End Sub
Sub lnkb_next_Click(sender As Object, e As EventArgs)
gv_currentslide += 1
If gv_currentslide > gv_slidesnames.Length - 1 Then
gv_currentslide = 0
End If
img_slide.ImageUrl = gv_path & gv_slidesnames(gv_currentslide)
Viewstate("gv_currentslide") = gv_currentslide
End Sub
Sub lnkb_previous_Click(sender As Object, e As EventArgs)
gv_currentslide -= 1
If gv_currentslide < 0 Then
gv_currentslide = gv_slidesnames.Length - 1
End If
img_slide.ImageUrl = gv_path & gv_slidesnames(gv_currentslide)
Viewstate("gv_currentslide") = gv_currentslide
End Sub
View Source under IE of said code:
Quote:
<script language="javascript" type="text/javascript">
<!--
function __doPostBack(eventTarget, eventArgument) {
var theform;
if (window.navigator.appName.toLowerCase().indexOf("microsoft") > -1) {
theform = document._ctl0;
}
else {
theform = document.forms["_ctl0"];
}
theform.__EVENTTARGET.value = eventTarget.split("$").join(":");
theform.__EVENTARGUMENT.value = eventArgument;
theform.submit();
}
// -->
</script>
This doesn't seem to be the most efficient way to do things as surely any such activity is just entertaining additional overhead to produce the end result?