Web Languages and Standards

39K

Solutions

30K

Contributors

Web development can range from developing the simplest static single page of plain text to the most complex web-based internet applications, electronic businesses, and social network services using a wide variety of languages and standards, including the familiar HTML, JavaScript and jQuery, ASP and ASP.NET, PHP, ColdFusion, CSS, PHP, Flex and Flash, but also the implementation of a broad list of standards including XML, WSDL, SSDL, VoiceXML and many more.

Share tech news, updates, or what's on your mind.

Sign up to Post

Is there any issue with leaving this as is? I'm sending out image requests and getting this in the dev. console:

Resource interpreted as Document but transferred with MIME type image/gif

I do see the image requests going out. Just didn't know if this was an issue or if I could ignore this?
0
I have code that iterates through an array (which is fed by an object) and processes image sources to be invoked in an iframe. The issue is, I'm getting an  "Uncaught TypeError: Cannot read property 'appendChild' of null" ERROR only when reloading page. If I do a "Empty Cache and Hard reload" it seems to works fine 100%. If I navigate away and back it works fine 90% of the time. If I do a regular reload, the error occurs every time on the last line, of the initial image source ("document.body.appendChild(iframeTag);" ) in the following code.  I do however see the initial image source call going out :
function insertStaticTag(imgSrc) {
    var iframeTag = document.createElement("iframe");
    iframeTag.setAttribute("width", "1");
    iframeTag.setAttribute("height", "1");
    iframeTag.style.display = "none";
    iframeTag.style.border = "none";
    var imgTag = document.createElement("img");
    imgTag.src = detokenizeTags(imgSrc);
    iframeTag.appendChild(imgTag);
    document.body.appendChild(iframeTag);
};

Open in new window

Not sure what could be the issue? Any thoughts?

Thanks!
0
I had this question after viewing JavaScript: Issue with onClick.  I asked this question today as I had issues with making the function work in the first place.

I assume that the regular expression is correct as it should only accept dates in the 2016-12-30 format. I believed that adding a regular expression is sufficient for the date validation to work. Obviously I was wrong.

How do I make a regular expression work in JavaScript? Do I need to add an if loop with a boolean value?

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Test</title>
</head>
<script type="application/javascript" language="javascript">

	formIsOK = false;

	function checkDate() {
		
	var theExpression = /^[0-9]{4}\-(0[1-9]¦1[012])\-(0[1-9]|[12][0-9]3[01])/;
	var getDate = document.getElementById("theDate");
	var matchData = getDate.value.match(theExpression);
	
	var m = getDate.value.split("-");
	
	var theYear = m[0];
	var theMonth = m[1] - 1;
	var theDay = m[2];

	var newDate = new Date(theYear,theMonth,theDay);
	alert(newDate);
	formIsOK = true;
	}
</script>
<body>

<p>Date validation: </p>

<table width="200" border="1">
  <tbody>
    <tr>
      <td>Date</td>
      <td><label for="textfield">Text 

Open in new window

0
Is there software out there that can download and rip a website to a hard drive for offline viewing? that can download the Javascript etc..?Would like to have the option so when it downloads it gives me an option to download into directories, pictures go into images folder etc. Is there a server-side language php ripper too?
0
I've seen online an animated .jpg. When I right click on the "looped image" it has a .jpg file extension. Is this a .gif? How can a .jpg be animated?
0
I would like to know the proper way of creating a .php website. Is there such a thing called a tree directory?
0
I want to have an intranet and membership in-house website.

Windows Server 2016, Apache2.4 installed and working, PHP5.6 installed and working, both installed on C:.

Apache not recognising the two sites from the same IP address.

Here is what I have in Apache Conf file:
<VirtualHost *:80>
ServerName intranet
DocumentRoot "K:/www/Intranet"
</VirtualHost>

<VirtualHost *:80>
ServerName membership
DocumentRoot "K:/www/Membership"
</VirtualHost>

Greatful for any assistance.
0
What is this screen element called.  
I've heard it called the hamburger and the menu button.
What's the official name?
What are some of the other nicknames.
I'd also like some useful links on other UI/UX resources.
err
0
Hi everybody.
Let me clarify my obscure question.. Developing a hybrid mobile app, I have a page with a menu and some hidden ul element which appears if the related menu item is clicked. The jquery is the simplest one:
	 $('#view-folder-dropdown').on('click', function(){
		 $('#view-style-list').toggleClass('menu-visible');
	 });

Open in new window


Well the menu is not shown. But the strange thing is that, if I connect my phone to my pc and I open Chrome Device inspector to use debug tools, the menu suddenly appears.
If I have debugger already opened and I close and reopen the page where the menu is, the menu remains hidden, but if I disable anyone of its rules (for instance the width, or the border...), it suddenly appears. Once it appears, everything works fine, but if I exit the page and then enter it again, then the issue is there again.

Looking the DOM I see the class menu-visible is correctly applied to the right element but it looks like the click event set width and height of the drop-down to 0px.

These the css for drop-down class:
.drop-down {
border: 1px solid #e4e4e4;
min-width: 130px;
padding: 10px 0;
background: white;
position: absolute;
top: 40px;
left: -55px;
width: 150px !important;
min-height: 100px;
height: auto;
min-height: 100px;
z-index: 10;
display: none;
-webkit-box-shadow: 0px 2px 3px 0px #c5c5c5;
-moz-box-shadow: 0px 2px 3px 0px #c5c5c5;
-ms-box-shadow: 0px 2px 3px 0px #c5c5c5;
-o-box-shadow: 0px 2px 3px 0px #c5c5c5;
box-shadow: 0px 2px 3px 0px #c5c5c5;
}

Open in new window


Any idea about what's going wrong?
0
EE,

I want to be able to call this method in my CodeBehind
Utl.LogDebug_Add(StatusLogStringToAdd, hdnLogDebugChild, Session["skPost"]);

Open in new window

.  Like this
Utl.LogDebug_Add(StatusLogStringToAdd);

Open in new window


There must be a way to get the HiddenField and Session Variable within this Method and not have to pass them all the time.  The Session Variable and HiddenField have the same Key "skPost" and ID hdnLogDebugChild on EVERY page in this project.

Thank You
Sam

using System;
using System.Web;
using System.Web.UI.WebControls;

namespace templateT01.Site.Utilities
{
    public class Utl : System.Web.UI.Page
    {
        internal static void LogDebug_Add(string StatusLogStringToAdd, HiddenField hdnLogDebugChild, object Session)
        {
            string UrlAbsolute = HttpContext.Current.Request.Url.AbsolutePath;
            DateTimeOffset dt = DateTimeOffset.Now;

                hdnLogDebugChild.Value = dt.ToString("HH:mm:ss")
                //+ "-->" + Session["skPost"].ToString()
                + "-->" + Session.ToString()
                + ">" + UrlAbsolute
                + "-->" + StatusLogStringToAdd
                + "\r\n"
                + hdnLogDebugChild.Value;
            ;
        }
    }
}

Open in new window

0
0
I am new to React and need further clarification on was exactly a SyntheticEvent is.

Please explain and provide a little example.

Thanks.
0
I am new to React and am confused by this unit test:

https://jsbin.com/yerudasixu/edit?html,js,output

What cause the following output:
1..2
# tests 2
# pass  2

# ok


And where is is that 2 tests are configured??
0
How do I learn this version of Javascript?

I do have PluralSight and sometimes find videos good. But I also find them lengthy to complete compared to documents that pack in lots of info.

Thanks
0
I am a .NET Full Stack developer between assignments and with time to dig into a Javascript framework to help me get my next job.

Leanring Angular has the issue there's three versions to learn: 1.0, 1.5 and 2.0. React has one version (I assume)

Then there's the idea that React is even more valuable in the marketplace than Angular.

Is that true?

which is fastest to get conversant with in a crash course?

Thanks
0
At AngularJS.org I selected Chat and made up a username, then declared I was Not a Robot. Then I got this chat, but do not recognize the format...

What format is this? Where can I learn this protocol?

Here's a sample of what I saw...

#angularjs: http://angularjs.org/ | Docs: http://docs.angularjs.org/ | Latest release: 1.5.9 / 2.2.4 | Code Of Conduct: http://goo.gl/m7MHxk | Provide a working example here: http://plnkr.co/edit/tpl:nKLNBdve51sqOoKZAOUS | #ionic for Ionic questions | http://splintercode.github.io/is-angular-2-ready/ | Channel logs: http://goo.gl/8Wwttq | Be polite! ☃
[20:07] == RAnton [aec0162b@gateway/web/freenode/ip.174.192.22.43] has joined #angularjs
[20:07] == Bnaya [~Bnaya@unaffiliated/bnaya] has joined #angularjs
0
Hi,
I want to re-position the whole picture into center of the page, while still keeping everything like buttons, texts and other objects, still in the 'same' position on top of the picture file. What to adjust?
http://my-friend.co/Main/Default.aspx
0
Hi All
I'm trying to import some data from a page zipwho.com into a excel workbook.
i have set up a web query that looks like this
http://zipwho.com/?zip=["Ticker"]&city=&filters=--_--_--_--&state=&mode=zip
i have set the parameter to 34209 but when i run it, it just comes up with the home page.
I do not really have any experience with this so any help will be greatly appreciated
Thanks in advance
Elmo
0
Hi everybody.
Im here with the same old mobile app. I'm trying to capture an image through camera and put it in the page, but the calls seems to fail instantly when I click the button 'Take a picture'.
If it doesn't fail, when camera is activate it shutdown the main app. I installed the https://github.com/zebra1024/cordova-plugin-wezka-nativecamera plugin which should fix that but I can't get it working.

This is index.html of my testing app
<!DOCTYPE html>
<html>
    <head>
        <!--
        Customize this policy to fit your own app's needs. For more guidance, see:
            https://github.com/apache/cordova-plugin-whitelist/blob/master/README.md#content-security-policy
        Some notes:
            * gap: is required only on iOS (when using UIWebView) and is needed for JS->native communication
            * https://ssl.gstatic.com is required only on Android and is needed for TalkBack to function properly
            * Disables use of inline scripts in order to mitigate risk of XSS vulnerabilities. To change this:
                * Enable inline JS: add 'unsafe-inline' to default-src
        -->
        <!--<meta http-equiv="Content-Security-Policy" content="default-src 'self' data: gap: https://ssl.gstatic.com 'unsafe-eval'; style-src 'self' 'unsafe-inline'; media-src *; img-src 'self' data: content:;">-->

		<!--<meta http-equiv="Content-Security-Policy" content="default-src 'self' data: gap: ms-appdata: https://ssl.gstatic.com 'unsafe-eval'; style-src 

Open in new window

0
Hi everybody.
I'm working a mobile app with Cordova (always the same :)). Now i have to implement some OCR function and I found tesseract.js script.

As often it happens, at least to me, reading docs everything looks to be easy but I've just included tesseract.js in my test app (built just to exepriment this plugin) and I get this error:
Uncaught TypeError: Object function Object() { [native code] } has no method 'assign' 

Open in new window


This is my directory tree:
root
-- css
-- img
-- js
  -- index.js
  -- jquery-2.1.4.min.js
  -- tesseract.js
  -- worker.js

Open in new window


This s the related head section of my index.html:
        <script type="text/javascript" src="js/jquery-2.1.4.min.js"></script>
        <script type="text/javascript" src="js/worker.js"></script>
        <script type="text/javascript" src="js/tesseract.js"></script>
        <script type="text/javascript" src="cordova.js"></script>
        <script type="text/javascript" src="js/index.js"></script>		
        <title>Hello OCR</title>

Open in new window


I see many other get it work and I'm wondering what I'm doing wrong....
As usual, any help will be deeply appreciated.

Cheers
0
Hi,
I do not know in the following,

http://my-friend.co/Main/Default.aspx

I cannot see the details within <div class="container">. I expect to see the details on the web page.
0
Hi Experts

When using Laravel when is better to use Alias and when is better to use Virtual Hosts?

At first sight the final result is the same. Conceptually what's the difference?


Thanks in advance.
0
Hi,
I expect the picture file to be shown as the background of the header, TABs (picture file would be right shown behind them). How to adjust the following?

<body>
    <form id="main_form" runat="server">
    <div class="content" id="wrapper" >
        <asp:Image ID="img1" ImageUrl="~/../pict/ID-10028343.jpg" CssClass="background" Height="780px" Width="1220px" runat="server"/>
    </div>
    <div class="container">
			    <!-- freshdesignweb top bar -->
                <div class="freshdesignweb-top">
                    <a href="http://my-friend.co/login5/Default.aspx" target="_blank">主页</a>
                    <span class="right">
                        <a href="http://my-friend.co/login5/Default.aspx/drop-down-responsive-menu-with-css3-and-jquery.html">
                            <strong>登入</strong>
                        </a>
                    </span>
                    <div class="clr"></div>
                </div><!--/ freshdesignweb top bar -->
			    <header>
				    <h1><span>寻找而拥有</span>一个属于自己的天地</h1>
                </header>       
         <!-- start header here-->
	    <header>
		    <div id="fdw">
				    <!--nav-->
					    <nav>
						    <ul>
							    <li class="current"><a href="http://my-friend.co/login5/Default.aspx">新楼盘<span class="arrow"></span></a>
								    <ul style="display: none;" class="sub_menu">
									    <li class="arrow_top"></li>
									    <li><a class="subCurrent" href="http://my-friend.co/login5/Default.aspx">Home

Open in new window

0
Hi everybody.
I'm implementing hammer 2 to manage pressup and tap event on table rows. Everything works fine but I get an issue. This is my code:

$('#grid_in').hammer({time: 1000, domEvents: true}).on('pressup', 'tr)', function () {
    $(this).addClass('row-selected');
})
$('#grid_in').hammer({domEvents: true}).on('tap', 'tr:not(.row-selected)', function () {
    $(this).removeClass('row-selected');
});

Open in new window


So if I press for just a few time, the class is added and then immediately removed: it looks like pressup fires even if I press for less a second. What do I am missing?

Thank you for your help.
0
Hi,
How to re-position all sub-options (high-lighted in Green below) beneath the relevant TAB?
https://1drv.ms/i/s!Ai8CrEskdewXkyNMD8Y3_cBOzohg

by these codes
        .body {
            background-color:#1BA8E0;
            padding-top: 60px;
            padding-bottom: 40px;
        } 
        .sidebar-nav {
            padding: 9px 0;
        }
            .lb_bck{
                color: black;
                top: 30px;
                left: 1075px;
                width: 36px;
                height: 30px;
                font-size: large;
                font-weight: bold;
                text-decoration: none;
            }  
            .lb_bck:hover, .lb_reg:hover{
                background-color: black !important;
                color: white !important;
            }
            .lb_reg{
                color: black;
                top: 30px;
                left: 1185px;
                width: 36px;
                height: 30px;
                font-size:large;
                font-weight: bold;
                text-decoration: none;
            }    
        ul {
            list-style-type: none;
            margin: 0;
            padding: 0;
            overflow: hidden;
            background-color: #333;
        }

        ul.tab {
            list-style-type: none;
            margin: 0;
            padding: 0;
            overflow: hidden;
            border: 1px solid #ccc;
            background-color: #f1f1f1;
        }

        /* Float 

Open in new window

0

Web Languages and Standards

39K

Solutions

30K

Contributors

Web development can range from developing the simplest static single page of plain text to the most complex web-based internet applications, electronic businesses, and social network services using a wide variety of languages and standards, including the familiar HTML, JavaScript and jQuery, ASP and ASP.NET, PHP, ColdFusion, CSS, PHP, Flex and Flash, but also the implementation of a broad list of standards including XML, WSDL, SSDL, VoiceXML and many more.