PHP vs HTML
When I first started web design I thought PHP was the way to go. It had front and backend javascript capabilities and it was a mainstay in apache24 http server where index.html lives. A no brainer for the beginner. MySQL connectivity was a shoe-in. But then I quickly discovered that my aws s3 page did not accept php. I was also counting on PHP for session management but quickly discovered that cookies were unavoidable and I did not want cookies on my site. So eventually the thrill of PHP wore off and I dumped it along with my S3 page at AWS. And I found out also that AWS was really good ONLY for EC2 and route 53, and nothing else because of its complexity and unfriendly instructional pages.
But I still recommend PHP and MySQL for the beginner and u should use the XAMPP platform for starters. It became a personal choice for me to not use php.
So I kept my apache web server that came with php and hosted html instead by appending virtual hosts to my apache httpd file and referencing plain old html pages in htdocs. Very simple for a beginner.
I read recently that PHP powers 70% of the web so this must mean that apache24 is equally as widely used. Yet I don't much care for it. Nothing wrong with good old html. So let's now work on creating index.html, our homepage.
Evolving along throughout the design phase, the question of javascript comes about. I opted for JQuery instead of PHP. Ajax seemed to be the big thing as I could connect to either a PHP file or a java servlet which would then connect to my db. A lot of page functionality came along with JQuery too.
So javascript is a big consideration when designing, as is connectivity to a database. But what about just plain html, the centerpiece of design? Our page must have presentability from basic html to responsiveness using javascript. So html is merely copy and paste so we have a template to do other things like responsiveness and functionality.
There does not seem to be much to write about when it comes to html. To me it is just a template with headers and page tags. So for the beginner we can just jump into the html piece within minutes and create our first index.html page in apache and host it on localhost. But hold on a minute. Enter bootstrap and other forms of css and then we add complexity to html. My opinion about CSS is to just get the very basics done in the beginning. The beginner does not need all the CSS frills right away or the confusion with different versions of bootstrap. So my best advice is to use a basic html template with basic css like this
Show a quick bare bones example
Above is very basic look and feel, below we add more features with a home page example
Also go to my homepage and do a ctrl u to view my html and js..provide link to javasqlweb.org
Then up next
other
I will be writing more on these topics soon
Remember, I am providing only guidance and recommendations. The rest is up to u when it comes to researching and deploying everything.
Happy coding !!!
More to come….I will clarify this soon
Also need blurb on cors policy, same origin coding is necessary. Explain to beginner what cross origin means when including href on ur page. Beware
Discuss when cors became an issue..starting with chrome version 76 in 2019 and tightened grip in chrome version 85
While deving Do shift ctrl j on page, during dev, for errors..opens windows developer console to check for html and js errors...keep it open while testing the page
Point out that where origin is null we have cors issue...deving at c drive is not possible..u need to be on a server..use apache live or apache with localhost
Each dev environment is different...xampp and php is different from apache...best during dev to use same site references and when referring to other site use href with target as blank so new window is created….dont try to open other site in same window as current site