HTML (HyperText Markup Language) is the predominant markup language used for creating web pages.

learn more… | top users | synonyms

1
vote
4answers
107 views

Should I Include PHP code in HTML or HTML in PHP?

What is the best practice, to write my PHP code inside my HTML code or HTML inside PHP? PHP inside HMTL: <p class="lead">Welcome to the <?= COMPANY_NAME ?> website.</p> HTML ...
2
votes
2answers
92 views

Javascript Password Security

I'm extremely new to javascript (so I know there's already a thread here), but I couldn't understand how to implement it. My code is pretty much identical: <script language="javascript"> ...
-4
votes
0answers
38 views

Best resources for beginning front end development? [on hold]

My husband is interested in learning how to code. He is currently getting a degree in Psychology and isn't sure if he'll find a good career out of it so is considering being a developer as a fallback. ...
0
votes
1answer
25 views

Is it possible to use on focus event on form..?

I tried to find when and on what onfocus works.. Can some one tell me is it possible to trigger event when some one is viewing current form ?? I know it works on input,dropdown and textarea.. but ...
-1
votes
0answers
56 views

Writing html via Java

I have some information stored on my computer in text files. I use Java to manipulate, format, and process this data. I would like to write a program in Java that will result in the data appearing on ...
-1
votes
0answers
61 views

How to use a href link just like a button? Which can perform some event? [closed]

I need the help in web programming concept. I want to create a link which will perform a login redirection. I want a reader view which will display some information To perform login we have to open ...
-2
votes
0answers
27 views

Live feed statistics to website [closed]

I am trying to create a live display of all of my analytics accounts such as Twitter, Facebook, GPlus, Google Analyitics and a few others. The idea is to display all of these on a personal area of a ...
-1
votes
0answers
38 views

Nested website navigational menus [closed]

So, I have created a website that has a navigational menu made up of nested unordered list elements. For example, <ul> <li>Home <ul> <li>About Us</li> ...
-2
votes
0answers
40 views

How do I update the news on a news site? [closed]

I'm trying to create a small news site as a project over the summer and I wondered how bigger news sites goes about updating the news stories without needing to access the code and add it manually. Is ...
-1
votes
1answer
53 views

Should HTML or CSS files count toward a “lines of code” metric? [closed]

I was asked how many lines of code my web application contains. Is it appropriate to include presentation layer/template files such HTML and CSS files in this count? (Note that I am not able to have ...
-2
votes
0answers
29 views

Angular service with different angular app [migrated]

Here i am using angular service.In my case i am getting value for first app but not for second .please help me . thank you. here is my html:- <div ng-app="mainApp" ...
4
votes
1answer
191 views

Is localStorage under The Cookie Law?

I'd like to avoid having the cookies banner on my websites where possible. Could I store session id's in localStorage to bypass implementing the banner?
0
votes
0answers
38 views

Synchronizing webpage and local pdf

I would like to solve the following problem. On my website, I have a list of my publications. I also have my list of publications on a latex file of my cv. The issue is that I update these manually, ...
0
votes
0answers
23 views

JavaScript top and left positions not working? [migrated]

I have this code in JavaScript on a html file but when i run it the image that i have doesn't move when i change top or left. Why is this happening, i have been searching for hours and copying tones ...
5
votes
0answers
68 views

Is progressive HTTP download a viable alternative to HLS/DASH/RTMP for providing live video?

I'm working on a website that needs to stream live video to users, and as such I've had to get my head around the sorry state of current browser-based video-streaming technology. The most popular ...
1
vote
2answers
81 views

Where to declare event handlers: Markup or Script?

If the event handler is declared in the markup, it'd be (kind-of) adding presentation logic to HTML. <button id="btn" onClick="foo()">Click Me!</button> If the event handler is declared ...
0
votes
4answers
279 views

How can I keep browser URL secret when editing data?

Suppose, There is a user list. <a href="user/5">Edit</a> <a href="user/6">Edit</a> When a system user clicked to edit a user info. Then it goes to url to browser like as ...
-3
votes
2answers
58 views

In HTML and CSS what are the standard tab sizes? [closed]

I searched on Google but couldn't find an answer. I'd like to know what are the standard tab sizes for HTML and CSS. Is it 2 or 4?
0
votes
1answer
40 views

maintain rate of animation with requestAnimationFrame

I've noticed that HTML game developers are recommending the use of requestAnimationFrame as opposed to a timer for the animation loop. I understand that this can be optimized by the browser, but how ...
0
votes
2answers
37 views

Flag arguments in an html factory class

I have been told that flag arguments(boolean arguments) are a bad thing because it complicates the signature of the method and means that the method does more than one thing. An issue I have with ...
13
votes
2answers
2k views

How Do News Websites E.g. Forbes / Zdnet Seamlessly Merge One Webpage into Another?

If you go to E.g: http://www.forbes.com/sites/adrianbridgwater/2015/06/12/why-technology-has-to-be-continuous/ OR ...
1
vote
1answer
142 views

html/css/javascript for game ui's

I've been looking into game ui's recently. My conclusion is that html/css/javascript would be the perfect solution IF it was wrapped up in a nice C++ library that allowed for easy integration into ...
2
votes
0answers
58 views

Truncating HTML content at specific content blocks

I have HTML content in my DB and I would like to present a list of these individual items but truncate each of them so they're not fully displayed. I would like to keep truncated items ...
2
votes
2answers
218 views

Pre-Processors vs Pure Web [closed]

It seems like within the last few years or so HTML/CSS/JavaScript Preprocessors have exploded in quantity and general use. They're still not as common as pure HTML, CSS, and JS/jQuery, but their ...
0
votes
2answers
72 views

Is it appropriate to use the unordered list (ul) element for composite content

I recently had a thought of utilizing the unordered list element to represent a list of composite content (such as a product list with details or an image list with captions). For example: ...
0
votes
0answers
44 views

Web App - Better to load Large, low quality image or many html elements?

I'm creating a web application that is visually enormous. I'm talking 2 million pixels wide and 2 million pixels tall (about). My goal is to show dynamically changing spots all over the site. For ...
0
votes
2answers
165 views

Javascript inline event handling versus external jQuery event handlers

Working on a dynamic website that loads information from a JSON file and then populates the page with said elements. My question has to do with event handling - as of now, I don't see any reason as ...
1
vote
1answer
97 views

Multiple CS Sheets or Javascript

I have a homepage with a navigationBar on top of the Viewport contains two buttons. One is the default selected home button which calls/displays home.html. The other for example is Ubuntu which calls ...
1
vote
1answer
240 views

Best use of the React frontend framework

I've been using rails' erb template for my views, but I've recently been trying to incorporate React as my front end framework. I'm a little lost on how front end frameworks are supposed to be used. ...
138
votes
8answers
18k views

Why are people making tables with divs? [duplicate]

In modern web development I'm coming across this pattern ever more often. It looks like this: <div class="table"> <div class="row"> <div class="cell"></div> ...
1
vote
5answers
479 views

why are globals bad in javascript [duplicate]

I've been writing web applications for a while now , and everyone knows the one golden rule not to assign variables to the window object , don't ever assign a variable without using var. My ...
0
votes
0answers
132 views

Choosing a javascript framework for a massively multi-player game : React vs Ember 2 vs other better option

I'd like to add to my Ruby on Rails app a javascript front end using basically Rails a json api sending data to the front end. The question for me is: React or Ember 2 (or maybe another viable ...
0
votes
1answer
138 views

Detect request coming from iframe

I just had this awesome idea about simulating a single page application using iframes. I am using a framework that uses layouts to display pages. Luckily I can use an empty layout (meaning it has no ...
2
votes
1answer
494 views

When and why to use Page.ResolveUrl

So, i had a discussion with a colleague on why and where should we use Page.ResolveUrl("~/PageUrl.aspx") instead of ./PageUrl.aspx. For example, are there any differences between: <a ...
1
vote
2answers
171 views

Can i write html on one line only in my php code?

i need to embed a html 301 redirect in my php code and i wanted to save chars in my html. Can i write HTML on one line since it is parsed? Is there anything against this practice? ?> <!DOCTYPE ...
0
votes
1answer
111 views

Always set form input max length?

Background I'm looking to put together a single page web application with many form inputs. I've run into issues with other web pages where there is an ugly SQL error sent to the user if the ...
-1
votes
1answer
68 views

What is the easiest way to store a piece of text in an HTML page? [closed]

I'll say in advance - I have almost no experience with HTML. I am currently coding a game in Lua, which needs to access a piece of code from an HTML website using GET. My question is this: What is ...
1
vote
2answers
172 views

Semantics of heading levels in multiple sections in HTML5

I'm never quite sure what is the best, most semantic way to handle heading levels in HTML5 markup, when you have multiple sections. On one hand it makes sense to have an H1 heading as a title of a ...
1
vote
1answer
65 views

Is it OK to replace html on resize?

I was asked to take over a web project. It is supposed to be a responsive website, but the former programmer didn't write the HTML/CSS with responsivity in mind and adding code to make it responsive ...
2
votes
1answer
441 views

Does react.js make sense for a static content-driven site?

I'm pretty sold on the react.js model because it makes DOM manipulation so smooth and comprehensible. But I'm wondering how it could be leveraged for a site that's largely static with big blocks of ...
1
vote
3answers
193 views

Is Doctype needed for HTML5 documents

Recently I had a job interview and one of the questions was "Is doctype needed for HTML 5 documents?". I've answered "no" but have a feeling that I might be wrong. From the w3 it looks like it is ...
1
vote
6answers
434 views

What to use instead of IDs in selectors in CSS

I recently installed a csslint package for my Atom text editor. I keep getting warnings saying "Don't use IDs in selectors." I found this weird since I've always been using IDs in selectors in CSS, ...
4
votes
4answers
959 views

Why is it (or was it) important to separate CSS from HTML? [duplicate]

Intro I recently watched the slides from React: CSS in JS and I really like the idea of having CSS applied using JS (and with JSX, this would mean having all the HTML, JS and CSS in one file, which ...
1
vote
1answer
73 views

torrent support in browser

i was thinking it would be cool to implement native torrent support in a web browser so that the following html would render an image on the page: <img ...
1
vote
3answers
350 views

Conceptually, is the single page web app more efficient than the web app that loads pieces of the page for every page? [closed]

I searched a lot, but nobody seems to have explained this nor given a proper example. I have a page like this: My team says they want to design the code such that the Title section, Menu ...
0
votes
2answers
32 views

Are there established guidelines for code formatting in included files with references to other files?

When developing for the web you will inevitably end up referencing a lot of files that eventually all get included and combined into a finished product. I specifically develop a lot of Wordpress sites ...
0
votes
1answer
130 views

MVC: Inserting a view from a SubController to its Parent controller

I have 2 controllers: 1 top level controller,MainController, and a SubController, which MainController has an instance of and controls. The SubController has a Subview which goes inside the MainView ...
1
vote
1answer
248 views

Is it okay to use CSS3 with HTML4?

Is it alright to use CSS3 with HTML4. It seems like CSS3 would be a HTML5 complaint deal. But I'm not sure if that's the case. If it's not okay, what are the downfalls to using CSS3 with HTML4, ...
11
votes
0answers
203 views

Math model for a webpage layout? [closed]

While web-programmers surely know CSS/HTML rules by heart, and web-browsers have algorithms to render web-pages, what interests me whether there are any mathematical/theoretical models or at least ...
3
votes
1answer
52 views

(HTML) Form structure storage

In the context of a single-purpose website/application (for instance, based on Symfony2), I wish to have a set of forms fillable by users which then will be sent out as a formatted email (with the ...