Trending questions in Web Development

0 votes
1 answer

How to set data attributes in HTML elements?

Hello @kartik, HTML <div id="mydiv" data-myval="10"></div> JS var a = $('#mydiv').data('myval'); ...READ MORE

Oct 5, 2020 in JQuery by Niroj
• 82,880 points
967 views
0 votes
1 answer

How do I disable the views caching?

Hello @kartik, There is now a php artisan view:clear command ...READ MORE

Oct 1, 2020 in PHP by Niroj
• 82,880 points
1,098 views
0 votes
1 answer

How to Insert multiple rows in a single SQL query?

Hello @kartik, In SQL Server you can insert ...READ MORE

Jul 21, 2020 in PHP by Niroj
• 82,880 points
4,210 views
0 votes
1 answer

How to deploy node app that uses grunt to heroku?

Hello @kartik, npm has a support for a postinstall step ...READ MORE

Oct 14, 2020 in Node-js by Niroj
• 82,880 points
527 views
0 votes
1 answer

How could i create carbon object from given datetime structure?

Hello @kartik, Use Carbon::parse('2020-09-25 14:26');, it will return a Carbon object. Hope it ...READ MORE

Sep 25, 2020 in Laravel by Niroj
• 82,880 points
1,345 views
0 votes
1 answer

How to get WordPress post featured image URL?

Hello @kartik, Try this code below: <?php if (has_post_thumbnail( $post->ID ...READ MORE

Aug 14, 2020 in PHP by Niroj
• 82,880 points
3,156 views
0 votes
1 answer

How can I use Sockets.io on the client side and communicate with a PHP based application on the server?

Hello @kartik, For 'long-lived connection' , you can ...READ MORE

Aug 24, 2020 in PHP by Niroj
• 82,880 points
2,722 views
0 votes
1 answer

How to get the first element of an array?

Hello @kartik, Try this: alert(ary[0]) Hope it helps!! Thank you ...READ MORE

Oct 5, 2020 in JQuery by Niroj
• 82,880 points
929 views
0 votes
1 answer

How to automate npm and bower install with grunt?

Hello @kartik, To install client side components during npm ...READ MORE

Oct 13, 2020 in Node-js by Niroj
• 82,880 points
556 views
0 votes
1 answer

How to use PHP's password_hash to hash and verify passwords?

Hello @kartik, Using password_hash is the recommended way to store ...READ MORE

Oct 6, 2020 in PHP by Niroj
• 82,880 points
842 views
0 votes
1 answer

How to to get the key of a key/value javascript object?

Hello @kartik, You would iterate inside the object ...READ MORE

Oct 9, 2020 in Java-Script by Niroj
• 82,880 points
705 views
0 votes
1 answer

How to return raw string with ApiController?

Hello @kartik, You could have your Web Api ...READ MORE

Jul 23, 2020 in Angular by Niroj
• 82,880 points
4,059 views
0 votes
1 answer

Error :jquery's .ajax() method not sending my session cookie

Hello @kartik, AJAX calls only send Cookies if ...READ MORE

Aug 25, 2020 in Java-Script by Niroj
• 82,880 points
2,633 views
0 votes
1 answer

Laravel Pagination links not including other GET parameters

Hello @kartik, I think you should use this ...READ MORE

Aug 4, 2020 in Laravel by Niroj
• 82,880 points
3,516 views
0 votes
1 answer

Error:ErrorException in Filesystem.php

Hello @kartik, Try this: chmod -R gu+w storage chmod -R ...READ MORE

Sep 25, 2020 in Laravel by Niroj
• 82,880 points
1,264 views
0 votes
1 answer

How to delete element by value in array (not key) using php?

Hello @kartik, Using array_search() and unset, try the following: if (($key = ...READ MORE

Sep 16, 2020 in PHP by Niroj
• 82,880 points
1,652 views
0 votes
1 answer

Error:npm WARN package.json: No repository field

Hello @kartik, It's just a check as of NPM ...READ MORE

Jul 20, 2020 in Node-js by Niroj
• 82,880 points
4,140 views
0 votes
1 answer

How to convert PHP code to MySQL query to CSV?

Hello @kartik, Try this: SELECT * INTO OUTFILE "c:/mydata.csv" FIELDS ...READ MORE

Aug 20, 2020 in PHP by Niroj
• 82,880 points
2,788 views
0 votes
1 answer

How can I select and upload multiple files with HTML and PHP using HTTP POST?

Hello @kartik, This is possible in HTML5. Example (PHP ...READ MORE

Sep 15, 2020 in PHP by Niroj
• 82,880 points
1,675 views
0 votes
1 answer

Error:nvm is not compatible with the npm config "prefix" option:

Hello @kartik, After installing nvm using brew, create ~/.nvm directory: $ ...READ MORE

Jul 15, 2020 in Node-js by Niroj
• 82,880 points
4,273 views
0 votes
1 answer

How to disable postback on an asp Button in System.Web.UI.WebControls.Button?

Hello @kartik, Use this: <asp:button runat="server".... OnClientClick="myfunction(); return false;" ...READ MORE

Sep 9, 2020 in Java-Script by Niroj
• 82,880 points
1,852 views
0 votes
2 answers

How to override trait function and call it from the overridden function?

instead of: return traitcalc($v); use this: ...READ MORE

Dec 13, 2020 in PHP by Uncle Nick
3,096 views
0 votes
1 answer

How can I refresh a page with jQuery?

Hello @kartik, Use location.reload(): $('#something').click(function() { location.reload(); }); The reload() function ...READ MORE

Sep 10, 2020 in JQuery by Niroj
• 82,880 points
1,777 views
0 votes
1 answer

How to trigger XDebug profiler for a command line PHP script?

Hello @kartik, You can pass INI settings with ...READ MORE

Sep 17, 2020 in PHP by Niroj
• 82,880 points
1,437 views
0 votes
1 answer

How to disable HTML button using JavaScript?

Hello @kartik, To disable document.getElementById("btnPlaceOrder").disabled = true; To enable document.getElementById("btnPlaceOrder").disabled ...READ MORE

Oct 9, 2020 in Java-Script by Niroj
• 82,880 points
470 views
0 votes
1 answer

How do I break a string across more than one line of code in JavaScript?

Hello @kartik, In your example, you can break ...READ MORE

Oct 8, 2020 in Java-Script by Niroj
• 82,880 points
507 views
0 votes
2 answers

How can I set focus on an element in an HTML form using JavaScript?

Hi Kartik, try the following script <script>  (window.onload = ...READ MORE

Sep 24, 2020 in Java-Script by Okugbe
• 280 points
1,555 views
0 votes
1 answer

How can I submit a form using JavaScript?

Hello @kartik, Set the name attribute of your form to "theForm" and ...READ MORE

Oct 9, 2020 in Java-Script by Niroj
• 82,880 points
462 views
0 votes
1 answer

How do I link a JavaScript file to a HTML file?

Hello @kartik, This is how you link a ...READ MORE

Oct 8, 2020 in Java-Script by Niroj
• 82,880 points
464 views
0 votes
1 answer

How to import jQuery UI using ES6/ES7 syntax?

Hii, Add a alias in webpack config: resolve: { ...READ MORE

Apr 28, 2020 in JQuery by Niroj
• 82,880 points
7,472 views
0 votes
1 answer

Error: Warning: Illegal string offset 'host' in ....

Hello @kartik,  Try this way: $memcachedConfig = array("host" => ...READ MORE

Aug 14, 2020 in PHP by Niroj
• 82,880 points
2,832 views
0 votes
1 answer

How can I query raw via Eloquent?

Hello @kartik, You may try this: // query can't ...READ MORE

Sep 24, 2020 in Laravel by Niroj
• 82,880 points
1,008 views
0 votes
1 answer

How PHP Replace last occurrence of a String in a String?

Hello @kartik, You can use this function: function str_lreplace($search, ...READ MORE

Aug 14, 2020 in PHP by Niroj
• 82,880 points
2,756 views
0 votes
0 answers

react question

when react can be called as complete ...READ MORE

Oct 7, 2020 in Web Development by Bhanuprakash
• 120 points
458 views
0 votes
1 answer

How change view folder in Laravel5?

Hello @kartik, See line 16 of config/view.php (the "View Storage ...READ MORE

Sep 25, 2020 in Laravel by Niroj
• 82,880 points
924 views
0 votes
1 answer

How can I check whether a radio button is selected with JavaScript?

Hello @kartik, You can use vanilla JavaScript way var radios ...READ MORE

Sep 3, 2020 in Java-Script by Niroj
• 82,880 points
1,875 views
0 votes
1 answer

How to insert an item into an array at a specific index?

Hello @kartik, You can implement the Array.insert method by doing ...READ MORE

Sep 10, 2020 in JQuery by Niroj
• 82,880 points
1,553 views
0 votes
1 answer

How to get the request parameters in symfony2

Hello @kartik, The naming is not all that ...READ MORE

Aug 14, 2020 in PHP by Niroj
• 82,880 points
2,739 views
0 votes
0 answers

How do I access to a variable inside a function?

I mean,I have public class MyClass{ ...READ MORE

Sep 21, 2020 in Laravel by aakash
• 230 points

edited Sep 21, 2020 by Niroj 1,110 views
0 votes
1 answer

How to execute a function when page has fully loaded?

Hello @kartik, That's called load. It came waaaaay before ...READ MORE

Sep 23, 2020 in Java-Script by Niroj
• 82,880 points
983 views
0 votes
1 answer

How to search for highest key/index in an array?

Hello @kartik, This should work fine $arr = array( ...READ MORE

Oct 6, 2020 in PHP by Niroj
• 82,880 points
420 views
0 votes
2 answers

How to animate a change in backgroundColor using jQuery on mouseover?

You don't need jquery. You can also ...READ MORE

Sep 9, 2020 in Java-Script by Eureka
• 160 points
1,698 views
0 votes
1 answer

How to move columns in a MySQL table?

Hello @kartik, If empName is a VARCHAR(50) column: ALTER ...READ MORE

Aug 19, 2020 in PHP by Niroj
• 82,880 points
2,500 views
0 votes
1 answer

How to dynamically load JS inside JS?

Hello @kartik, The script is not added to ...READ MORE

Aug 25, 2020 in Java-Script by Niroj
• 82,880 points
2,232 views
0 votes
1 answer

How do I modify the URL without reloading the page?

Hii @kartik, HTML5 introduced the history.pushState() and history.replaceState() methods, which allow you ...READ MORE

Jun 20, 2020 in Java-Script by Niroj
• 82,880 points
5,091 views
0 votes
1 answer

How to alter a MySQL column to be AUTO_INCREMENT?

Hello @kartik, Try this: ALTER TABLE document MODIFY COLUMN ...READ MORE

Aug 19, 2020 in PHP by Niroj
• 82,880 points
2,477 views
+1 vote
1 answer

Error:file_put_contents(meta/services.json): failed to open stream: Permission denied?

Hello @kartik, Below steps helped me fix the ...READ MORE

Apr 3, 2020 in Laravel by Niroj
• 82,880 points
8,367 views
0 votes
1 answer

How can I declare a global variable in php?

Hello @kartik, The $GLOBALS array can be used instead: $GLOBALS['a'] = ...READ MORE

Oct 1, 2020 in PHP by Niroj
• 82,880 points
553 views
0 votes
1 answer

How to generating a random password in php?

Hello @kartik, Try this (use strlen instead of count, because count on a ...READ MORE

Sep 29, 2020 in Laravel by Niroj
• 82,880 points
620 views