Is there any equivalent to Response.End
in PHP?
mercredi 7 septembre 2016
How do I model a database for an e-commerce website usin MySQL?
How do I model a database for an e-commerce website usin MySQL?
How to convert an ascii character into an int in C
How can I convert an ascii character into an int in C?
How to redirect from one URL to another URL?
How can I redirect to another URL in a web page using JavaScript?
Copying from my variable to a Microsoft Word using javascript in Google Chrome
i try using ActiveXObject, but in Google Chrome had error: ActiveXObject is not defined
How do you strip whitespace from an array using PHP?
I was wondering how can I strip white space from an array using PHP?
Detect if mbstring is enabled or not from PHP script
How can I check if the mbstring extension is loaded in a php script?
Secure mp3 file uploads scripts with database connectivity
Secure mp3 file uploads scripts with database connectivity where users can uploads only mp3 file
Is there a portable C compiler for windows?
I want to carry one in my flash drive and run it.
Thanks
Using boolean values in C
C doesn't have any built-in boolean types. What's the best way to use them in C?
Is there any I can use libhdfs api to read a file line by line?
As question said, Is there any I can use libhdfs api to read a file line by line?
mardi 6 septembre 2016
GoCardless Gateway OAuth method in php
I want to use Gocardless OAuth method in php but there is no any library available for it.
How to open a new tab using Selenium webdriver using PHP
Can someone point me to examples for opening a new tab using Selenium with PHP (without using Facebook php web driver)
How to stop displaying printf of a particular "c" daemon in linux
How can be stop displaying printf of a particular daemon on desire . By disabling a particular attribute can i ignore printf .
Can someone help me with Javascript comparisons?
I am looking to hire someone for help? Hoping to get someone who knows what they are doing.
Skype is ELOsharks.
What can be considered as advanced Php programming? [on hold]
As an Php intern I want to know which area in Php development is considered as acomplished or advanced? Just my curiosity, thanks!
Time series forecast using recurrent net libraries
I want to use recurrent neural network for multivariate time series forecast. Can anyone provide reference to some good C/C++ libraries for this.
Replace string without buildin function in php
How to replace string without existing function like str_replace()
in PHP.
Eg: $str = " Hello word";
$needle = "llo";
Wakaama (Lwm2m implementation in c)on Arduino Uno
i would like to use wakaama (Lwm2m implementation in c) on Arduino Uno. Please can somebody help me ? Thanks in advance.
Hezou
PDO with PHP7 and Microsoft SQL Server?
Is there a stable driver to use PDO with sqlserver 2014 and php7? If not, then what is the best way to access sqlsever 2014 with php7?
Any way to get JavaScript numbers without Euler's number
I try to get
Math.pow(2,1000);
The result is " 1.2676506002282294e+30 "
I need the number without Euler's number "e+30"
Having the tan(x), how can I get a tan(x/2)? In C
I know I can do this:
//With A = tax(x);
return tan(arctan(A)/2);
but I wanted something more efficient.
Compiling C/C++ for different platforms [on hold]
Is it possible to compile C/C++ into a Linux executable from Windows (gcc/g++.exe test -o test.linux-executable)? Or are they the same things?
How to stop php all execution using php single code [on hold]
How can we stop php code that execute from different areas of web. By placing only one code i don`t know how to do this
What is the difference between array and enum in C ?
I find enum to be similar to an array,with the elements in it being numbered from 0. So what is the difference between an array and enum?
How can i generate code coverage for native shared library(.so files) or for Native Code(C/C++) in android Studio?
The JNI library is already linked to android studio.Is there any plugins which can generate code coverage report for native shared libraries or for native codes??
Javascript equivalent of php's strtotime()?
In PHP, you can easily convert an English textual datetime description into a proper date with strtotime()
.
Is there anything similar in Javascript?
what are ( Angular, Node.js, AJAX, JQuery)?
I really have a hard time to distinguish between all those frameworks, libraries or API I don't know, and how they related to each if they do.
Specific letters and digit in a string in c programming
How to check for user input if I want to start with a character follow by 7 digit and end with a letter in c programming? Example; S1234567A
Is Caching data in browser same as using local storage or cookies?
I am a bit confused between caching and using browser's local storage to store data. Are they both same? If not, can you please tell me the difference?
How do I store a 3 byte char as 6 hexadecimal characters in c
I have the following variable
char cArray[3]
How would I store cArray
as 6 hexadecimal characters in another char array variable?
What is the meaning of a number in brackets after a struct declaration?
I recently encountered text of the form
struct {
double a, b, c;
}[123];
What exactly does this do? Is this even proper C?
How to pause in C?
I am a beginner of C. I run the C program, but the window closes too fast before I can see anything. How can I pause the window?
lundi 5 septembre 2016
Symfony 3 - Last logged date
Trying to put the database date of the last login user, but completely do not know how to do it.
Please help and thank you in Advance.
What is the difference between *a=b and a=&b?
Given:
int **a; // (double pointer)
int *b; // (pointer)
Is there any difference between *a=b
and a=&b
?
Difference between *arr[] and **arr
Is the same
char* s1[size];
To
char** s2 = malloc(size * sizeof(char*));
They have any difference?
free() not deallocating memory?
free(str);
printf("%dn", str->listeners);
The call to printf succeeds (as do any other calls to str's members). How is this possible?
Any way to stop my laptop battery from charging while plugged in?
Is there any way to programmatically stop my battery on my laptop from charging while plugged in, when it gets to 100% but start charging again when it gets too 10%?
Symfony1.4 web configuration on server
I upload my Symfony1.4 into my server. Url like test.domainname.com/web will access the application but i want test.domainname.com/. Where exactly change please help me.
Publish events to Facebook with API V2
With Facebook API V1 it was possible to publish event. With API V2 this is not possible anymore. But Eventbrite still has this function. How do they do it?
JavaScript - Get minutes between two dates
If I have two dates, how can I use JavaScript to get the difference between the two dates in minutes?
How can I test if a sound is playing in SoundManager2?
I'm looking for a simple way to check if SoundManager2 is currently playing a sound. I was hoping for a function like "SoundManager.isSoundPlaying" but I don't see this functionality.
image cannot be displayed because its conain error in php [on hold]
$result = mysql_query("select profilepic from `profile` where id = '$pid' ");
if ($result) {
if ($row = mysql_fetch_array($result)) {
$img = $row["profilepic"];
}
}
header("Content-type: image/jpeg");
echo $img;
How to parse plain text in php
Title: fsf
Length: 125
Link: http://www.example.com/
How to parse plain text in php?? I want to get the link mentioned in the file using php
How to Make Save Button for Save Image on Video HTML5
in HTML5 Video, we can right click video and choose "Save image as..."
i want to make a button to automaticly save the image
please help, thanks
What is the difference between casting to `float` and adding `f` as a suffix when initializing a `float`?
What is the difference between
float f = (float) 99.32 ;
and
float f = 99.32f ;
Both of them compiled and ran successfully.
How to check how much from heap and from stack my program is using?
I'm using Visual Studio 2013 on Windows 7 - 64 bit machine.
I'm writing a program on C.
How can I check how much heap and stack storage my program is using?
Google Charts tooltip flickering
When using Google Charts, sometimes the tooltip appears behind the mouse pointer, causing a flickering when the mouse is moved, even a little bit.
Is this a known issue?
How can I add a BCC to my code
Mail::send(['html' => 'emailtemplate'], $dataCustomer, function ($m) use ($input)
{
$m->from('quotes@email.net', 'Mr. Foot');
$m->to($_POST['email'])->subject('Mr Foot Thanks You');
Error handling/checking in the kernel realm
What is the equivalent to errno
in the kernel realm? More precisely, how do I check what error has happened for example when using a function like kmalloc()
?
XBee ZigBee Library for visual studio c++
I'm sending frame using XCTU (Windows side) to mbed CPU, That process I need to do it using visual studio (windows side). Any API that compatible with visual c++? Any help is appreciated.
Creating a PHP Generator in a C PHP Extension
Does anybody know how to write a simple php generator that does something like, addition, written in c
I'm trying to find examples of this, but I'm coming up with nothing.
Easy way to password-protect php page
I have a page I want to password-protect. I've tried doing HTTP authentication, but for some reason it doesn't work on my hosting. Any other quick (and easy) way to do this? Thanks!
Video views in android app
I am trying to get a count of who have watch or is currently watching the video in my application . Kind of like youtube would anybody know how to approach it by any chance.
Looking for a stacked bar plugin
I am looking for a single lined stacked bar plugin (can be either Jquery or JS).
It should look like this:
Antiword binary /usr/local/bin/antiword does not exist
I am downloading cats open source ats software.When I ran installtest.php this error occurred:
Antiword binary /usr/local/bin/antiword does not exist.
Please suggest a solution.
dimanche 4 septembre 2016
Meaningful C/C++ algorithm with bad cpu cache utilization characteristics, but have room to be improved significantly [on hold]
What are some suggestion for meaningful programs which initially have slow performance due to bad CPU cache utilization patterns, but have significant room for improvement in performance?
Target CPU: Intel Core i7 4xxx
How to search a video in C?
I would ask if it's possible search a video with C and socket? Is there a function to do that? If yes, is possible view info video like views, comment, like, time video etc.
Header with memory size definitions
Is there standard C/C++ header with definitions of byte, kilobyte, megabyte, ... ? I dont want to make own defines. It's dirty in my opinion.
Example:
if (size > MEGABYTE)
{ ... }
Wordpress theme development issue
I'm trying to convert my static theme into WordPress theme, but face this error. how can i resolve this?
How can a Laravel 4 class detect that it is running in an Artisan task vs. a browser request?
I have some application boot code that needs to know if it is currently running in an artisan task vs. being called in a browser request.
How do I detect this in Laravel 4?
Hi , I got a error when I try to access to service web ... php_network_getaddresses: getaddrinfo failed: Name or service not known
php_network_getaddresses: getaddrinfo failed: Name or service not known.
I don't have idea what is wrong this.! error image
How can I connect to database from C program [on hold]
I am new in developing the applications in C language. Can anybody give me the code how to connect to database from C application? Thanks in advance.
PS: I using IDE codeblock, database mysql
returning char** from C DLL to VB
Please, I am developing a VB app to call a C DLL function and I need to pass from VB to C DLL a char** to receive the reply. How can I do that? Thanks everybody!
PHP array compare and if statement
$x1 = 'xxx';
$y1 = 'yyy';
$a=['xxx', 'xxx', 'xxx'];
$b=['yyy' => 1, 'yyy' => 2, 'yyy' => 3]; ;
if($x1== $a){ if($y1== $b['yyy']){ $cat= $b['1']; } }
I need help with this logic.
How can I emulate right-click in the node.js selenium-webdriver?
I am using selenium-webdriver for nodejs.
How can I emulate a right-click with this driver? I can't find this in the official documentation.
preg_replace produces unexpected duplicate with a very simple RegEx
var_dump(
preg_replace('/.?$/s', "x", 'abc'),
preg_replace('/.$/s', "x", 'abc')
);
Outputs:
string(4) "abxx" <-- strange, isn't it?
string(3) "abx"
How's that possible?
How do l write mysql_result ($query_run, 0, "user_id") using mysqli
l want to write the following code in mysqli
return(mysql_result($query_run,0,"user_id"));
Please how do l do this..have been knocking my head for days about it. thanks ahead
Freeing all malloc()-created pointers with one command?
Is there a one-liner that will free the memory that is being taken by all pointers you created using malloc
s? Or can this only be done manually by free
ing every pointer separately?
C prototype of a function with define name_fn in a body
Could you help me understand what the following piece of code means? Specifically, I do not understand what the effect of name_fn
is.
#define name_fn
void name_fn Function(void);
How can I detect when an RTMP live stream comes online, either through ActionScript or JavaScript?
I want to find out when an rtmp://
live stream URL is sending over data (if the user is streaming or not).
How can I do this using either ActionScript (3.0) or in JavaScript/PHP?
Unable to Install Phalcon
While Installing Phalcon for PHP7, I am getting error:
Cannot find build files at '/Applications/MAMP/bin/php/php7.0.0/lib/php/build'. Please check your PHP installation.
I am using MAMP.
How to use buttons to open up a html app in a new window?
Code here!: https://ghostbin.com/paste/xmxg8
How do I make a button open up my calendar program in a new window on the same screen?
wordpress get the title in javascript
in a PHP file is possible get the title of a post with
the_title();
is it possible, in a JS file, get the title of a post?
many thanks
How to get window position from vanilla JS and/or jQuery
How does one get the window position, cross-browser, in JavaScript?
Also, if calling .position
on $(window)
in jQuery, I get an error. Is there another way to get $(window).position()
?
WordPress top download counter plugin or php codes
I'm working on a project where in a section users will see the top 10 downloads. Do anyone know how to do this. The project is on WordPress. Any plugin suggestions or raw php codes both will be okay.
how I decide the masking whether I have to use 0x0F,0xF1 [on hold]
Although this might be a silly question but I don't know why 0x0F is chosen for masking,generally ? eg. in Java
byte b = (byte)0xF1;
(b>>4)& 0x0F
Modify article on the fly in Joomla
I can change a title by placing the next line into my template:
$doc->setTitle('my new title');
But is any method to modify an article's 'fulltext' in the same way?
If Input is 6 what will be the output and why?
#include<stdio.h>
#include<math.h>
void main(main)
{
printf("%d",main=getche(printf("%d",main+=pow(++main,++main))));
}
If Input is 6 what will be the output and why? I got 3 0 48
Selecting all messages from individual ips that has 20 or more messages
I'm trying to select all the messages from individual ips that has 20 or more messages, but I'm having trouble selecting it. Here's my query:
SELECT messages
FROM currentChat
HAVING count(id) >= 20
GROUP by ip
samedi 3 septembre 2016
Eclipse Jelly script plugin
is there any Jelly script plug-in for Eclipse IDE.I want to debug one of the Jelly scripts I'm using inside Eclipse editor ? Is there any support for Jelly debugging ? an advice please...
Thank you
maximum of 3 numbers in c lang [on hold]
I want to give 3 numbers which will give output something like this: It could be array or direct numbers:
Input: 2 3 6
Output: 6 > 3 > 2
Input: 4 1 8
Output: 8 > 4 > 1
Input: 1 1 1
Output: 1 = 1 = 1
Input: 1 1 5
Output: 5 > 1 = 1
Input: 5 5 3
Output: 5 = 5 > 3
Link id's between two mysql tables
Well, I have two tables, onde for the posts of a blog and another for the images of the posts, wich only stores the name of the images. How can I link a post id to a photo id?
How can I convert string to datetime with format specification in JavaScript?
How can I convert a string to a date time object in javascript by specifying a format string?
I am looking for something like:
var dateTime = convertToDateTime("23.11.2009 12:34:56", "dd.MM.yyyy HH:mm:ss");
How to display a readable array - Laravel
After I write:
Route::get('/', function()
{
dd(User::all());
});
And after I refresh the browser I get an unreadable array. Is there a way to get that array in a readable format?
How to add SKU coloum at Products Bestsellers Report tools in Magento?
I want to add SKU new column at products bestsellers report in Magento 1.9.2.
Admin->reports->product->bestsellers report
I dont know how to add it.
Please suggest.
How to debug Pro*C code?
We have a legacy code written in Pro*C which now needs to refactored. is there any debugger which supports debugging pro c code.
is it possible to debug using .c/.cpp produced after proc*C pre compilation
regular expression for sequential numbers like 12345 or 456789 javascript
I need to prevent entering 5 degit sequential numbers like 12345,45678 etc. in a text box.
I have tried with the following regular expression,but it is not working
var regex = /^(?[0-9]{3}(-|)) ?[0-9]{3}-[0-9]{4}$/;
C++ / C #define macro calculation
Suppose I have
#define DETUNE1 sqrt(7)-sqrt(5)
#define DETUNE2 sqrt(11)-sqrt(7)
And I call these multiple times in my program.
Are DETUNE1 and DETUNE2 calculated every time it is called?
How to convert ISO 8601 with timezone to C# Datetime?
How can i convert ISO 8601 with timezone to c# actual (local) datetime format.
my ISO 8601 date is like "2016-06-19T19:30:43+04:30
"
and I need something like this "2016-06-19 16:00:43
"
Can we assign a value to a given memory location?
I want to assign some value (say 2345) to a memory location(say 0X12AED567). Can this be done?
In other words, how can I implement the following function?
void AssignValToPointer(uint32_t pointer, int value)
{
}
Javascript show div after a few clicks
I'm new in Javascript and I can't find the answer for my question. Is it possible that my javascript views a div after if you clicked 5 times? If this is the case, how can I make this possible?
Thanks!
CSS - width and height size depending on backgroun-image?
Is there a way to set up my div size with the background-image default size?
like having an img tag inside a div, the div is set up to width: 100%; and height: auto; so my img will its default size
sharing posts in different website at the same time
I want to make a php script to post posts in different webistes, like facebook,twitter and instgram
once the user enter the link of the page and his post . the post will be displayed in different social media websites
Rename propel.php configuration file
Is it possible to rename the default naming of propel.php
and propel.php.dist
and pass the arbitrary value to propel model:build
? For example
propel model:build --input-file="./MyPropelFile.php"
Why use #define for registers instead of constants?
If you declare it as a constant you can also specify the type (size) of the register and let the compiler provide its assistance.
Why is it a common practice to use #define
for register name-value declaration instead of constants?
js lib or lib in any language for providing social locker functionality? (e.g. you get a free trial by sharing on twitter)
I've been spending a fair amount of time googling for this. There is a social locker for wordpress and of course many companies offer this type of thing for a fee, shouldn't there be a simple free plugin that does this too?
About Bitwise operator
if((x & 1) == 0)
printf("EVEN!n");
else
printf("ODD!n");
why X&1
will always gives 1
when number is odd.. I mean what is happening in memory during this operation can any one explain it ?
link 4 video element to one source
Help me link one video source to 4 elements. The force src assignation is very CPU expensive as 4 network streams and 4 video encodes produces
//very very CPU expensive
video1.src= sameSource
video2.src= sameSource
video3.src= sameSource
video4.src= sameSource
Semaphores and Mutex behaviour doubts
Do semaphores and mutexes synchronize both threads and processes, or only threads, or only processes?
Edit: my mistake it's C, not shell. Since I programmed through the shell I mistook it. And one more thing: are communication and synchronization the same?
How to draw a button using winAPI
I have successfully created an owner drawn button.
But how do I now draw/color the darn thing, to make it look like a Button using the Windows API? Currently, it just looks like a colored label?
Any C examples?
catch php commands while executing
Are there any methods to catch the php commands instead of executing them? There's a backdoor which is encoded in my server, I was able to get declared classes and methods names, of the backdoor, but I need to find out the real code.
Will a child process send SIGCHLD on abort()?
If an application does a fork()
and the child dies with an abort()
(due to failing an assert()
), will the parent process receive a SIGCHLD
?
If it's relevant this is on Debian 4 (gcc version 4.1.2).
Mysql help for selecting two table using array
I have an array with values inside array("tblone","tbletwo") Where tbleone and tbletwo are table name and both table have different data inside them I want to query both data sametime using array Can I use UNION with fetching table name from array?
vendredi 2 septembre 2016
MAGENTO: Clean Exeption.log and System.log
Exception.log and System.log under /var/log folder in Magento are over 2gb each.
Is it safe to clean them? If yes, what is the proper way of cleaning such logs?
Really appreciate all suggestions!
How to add static .js files to Meteor project?
Sorry for my english. I have a functions.js file, where I put all my js code. The functions.js doesn't refer to Meteor. Where do I place the functions.js file so that it is attached to the template?
Thanks in advance.
How do I get the count of all the HTML event attributes used in a page?
Using jQuery, how can I get the count of all HTML event attributes (http://www.w3schools.com/tags/ref_eventattributes.asp) used in any webpage where I embed my script?
What's wrong with my code? Changing colour to a div slowly
Does anyone know why my code doesn't work? I want to change the color of a div slowly.
function fadein() {
change = document.getElementsByClassName("load_1")[0]
setInterval(function(){
change.style.color = "rgb("+x+","+x+","+x+")";
x=x+1
}, 200)
};
function animate(){
var x=0;
fadein()
};
animate()
Malloc in If Statement in C
i am new in c, and i can not understand following piece of code. If anyone can explain it, i am really happy. Thanks in advance.
if( ! ( st_cur = (struct ST_info *) malloc(sizeof( struct ST_info ) ) ) )
{
perror( "malloc failed" );
return( 1 );
}
How to convert RGB to NV12 color format in C or C++? [on hold]
NV12 format is YUV 4:2:0 format ordered in memory with a Y plane first, then the subsampled chroma data in an interleaved UV plane.
Example:
YYYYYY
YYYYYY
UVUVUV
Using malloc to communicate between parent and child
If I ask for memory size of an int from malloc and I create 'n' child processes from one parent. Is it posible for each child to update(add one) the value inside that memory, so by the end the parent process reads the value?
Cassandra Database Use Cases
Different articles i saw that cassandra database can use for
1) User activity tracking and monitoring
2) Social media analytics and recommendation engines
Anyone having idea about this use cases. How can achieve theses Or any tutorials available in the market?
How to change the css color code permanent using php
I'm trying to make theme in user part, so i can select the color for the website. what i need is - when i selected the color it should change the color code in style.css and save. Files : index.php and style.css or php
How to filter MySQL table data using multiple options
For example if I have a table products in this name brand and price are columns i want my website user can filter from name and or brand and or price . From dropdown or checkbox or any method. Plz help me soon I am totally beginner .....
How to get php timestamp to the speciefied format with timezone? [duplicate]
This question already has an answer here:
- format mysql timestamp using php 4 answers
i want curerent timestamp in this format 2012-04-23 18:25:43.511000+00:00 .Please help
How to create an option where client can upload a mysql database to the server through php code?
Iam making a website where people can upload their works... s,o if the client has a mysql database how can I make an option where he can upload that database to my server through a php code ?
As always, any help is appreciated :)
retrieving data from apache web server to arduino using ESP module 8266
I have posted the LDR sensor data to apache web server using NODE MCU v1.0 ESP12E with the help of php script.Now, i want to retrieve the data back into arduino using using ESP 8266 module.can any one help me with the arduino code.....??
How to translate C code to COQ [on hold]
I want to model a cryptographic library in COQ which is written in C language.
For that I need methods to translate the C code to COQ Gallina code.
Are there COQ libaries/tools which can help translate code form C to COQ's functional language?
Google AdWords Scripts Get Views
Good day
I have a question about Scripts in Google AdWords.
I know you can't modify frequency cap in a video ad, but I want to check impressions and views. Impressions is in the Stats Object, but where I can find views?
receiving an array of objects in client side from c#
I need receive the following array of objects in my client side from c#: [Object, Object, Object, Object]
0:Object
1:Object
id:"myID1"
category:"Software Practices..."
title:"Writing Code..."
2:Object
3:Object
I'm using this array in my JavaScript code. Thank you.
php code to push conditional values in to array
I have variables with values:
$abc = 'Y';
$xyz = 'N';
$pqr = 'Y';
$lmn = 'Y';
I want to create all the variables with value 'Y'
in to an array, similar to as below:
$result = ( abc, pqr, lmn)
Is there a printf converter to print in binary format?
I can print with printf as a hex or octal number. Is there a format tag to print as binary, or arbitrary base?
I am running gcc.
printf("%d %x %on", 10, 10, 10); //prints "10 A 12n"
print("%bn", 10); // prints "%bn"
How to produce beep sound using "a" escape character?
If I write the following program, then there is no beep sound on running the code.
#include <stdio.h>
int main()
{
printf("a");
return 0;
}
Can you tell me how to use a for producing beep sound using C program ?
C Programming, Logical Operators [on hold]
I am having problem with two of my homework questions about C programming.
x = 0x66
y = 0x39
What are the values for:
x & !y
x && y
Thank you in advance for your help!
Jump to Reset Vector
I am trying to jump back to the reset vector and re run my program from main. This is my code but it does not work. Is there anything wrong with this?
typedef void (*reset_vector_jump)(void);
((reset_vector_jump)RESET_VECTOR_ADDRESS)();
The mbstring extension is missing. Please check your PHP configuration
phpMyAdmin Error: The mbstring extension is missing. Please check your PHP configuration
I have already tried all of the solutions on this and none of them have worked for me. I am not sure what else to do.
Check two location(latitude, longlatitude) near in 2000 meters
I have two location latitude, long-latitude. I need to check 2nd location available within 2000 meters with first 1st location.
Also i have location array an i want to check with 1st location. I need result how many available in 2000 meters
Thanks,
Bharat Bhola
How to protect Python source code?
Is it possible to distribute only the bytecode version (.pyc file) of a Python script instead of the original .py file? My app embeds the Python interpreter and calls PyImport_Import to load a script. How can I tell it to look for a .pyc file and import that?
jeudi 1 septembre 2016
PHP loop two messages every 4 days
I have been looking everywhere for a piece of code using php to echo a message every 4 days, so the first 4 days would display one message then the next 4 will display a second message, then for the code to loop its self indefinitely, any help would be greatly accepted.
how to compare ipv6 address in c without using memcmp
I have two ipv6 address stored in structure struct in6_addr
. I would like to find which one is smaller without using memcmp
. Is there a better way to compare ipv6 addresses?
struct in6_addr {
unsigned char s6_addr[16]; /* IPv6 address */
};
Jscript error - Why? - Uncaught TypeError: Cannot read property 'remove' of undefined
I have a script to remove uploaded files after Add to succes, but i get this error on site when it loads. "Uncaught TypeError: Cannot read property 'remove' of undefined" Whats missing?
<script>
onload=function() {
document.querySelectorAll("li[id^='uploadNameSpan']")[0].remove();
}
</script>
Alter behaviour of jQuery UI Dialog
I have a dialog defined with jQuery UI in this way:
this.dialog = $.dialog({
title: 'Title',
open: function () {
//do something
},
close: function () {
//do something else
}
});
How can I at a later point in my code override the behaviour of the close
method?
How to get users time based on location in wordpress or in php and they will see the time base on location in the website
I am developing a online radio station with wordpress.so i want that when a user browsing this site from usa he will see the program schedule based on his time.means i want user can see program schedule based on their time.so how can i do it in wordpress.
How do I retrieve an HTML element's actual width and height?
Suppose that I have a <div>
that I wish to center in the browser's display (viewport). To do so, I need to calculate the width and height of the <div>
element.
What should I use? Please include information on browser compatibility.
Laravel : how to check if a specific value was selected
I have a very newbie question in Laravel.
In the controller I want to create something like :
if ($Q_type = "specific Value selected by the end user in a radio button")
{
do an action
}
what is the syntax to check this specific value ?
Assign array of object content to a new array
I'm trying to assign an array of objects to another array but when I created the new array and in others functions I change its value, the original array changes as well (which is not ok). Could I use another way? This is an example: http ://codepen.io/Xiwi/pen/rLMbYp
Why this program wont break out of the loop and ask for input?
I have following code:
badinput:
scanf("%d", choice);
switch (choice){
case 1:
...
case 2:
...
case 3:
...
default: {print("try again");goto badinput;}
}
When I put 1 2 or 3 its ok when i input text, for example "a" program wont stop at next scanf
. What is the problem here
How to update just the metadata of the google drive file
I want to update the metadata of a google drive file. Just the description of the file. I referred this, but it is showing how to update the content of the file along with metadata. However I just want to update the metadata of the file. Any help will be appreciated.
why no overflow when using double variable?
i'm trying to understand why in the following situation i don't get an overflow:
double x = 1.7976931348623157E+308; //this is the max value of double
x = x + 0.5;
When checking the value of x after adding 0.5 i still get the same result
.
Anyone?
How I can determine which key is pressed on keyboard? C++
How I can determine which key is pressed on keyboard in C++ using WINAPI?
I try to use GetAsyncKeyState
, but it work just for exactly one key, and I need to choose which one, but I need to get keyсode to it be send over tcp.
Diffrence between Simple Router like (CodeIgniter) and Restful Router (Slim Php)
I am a novice PHP coder. Have basic knowledge in php [Self taught]. Presently learning CodeIgniter. But recently checked Slim Php Framework. It has Restful Router.
Can any one please tell, what is difference between CodeIgniter Router and Slim Router. And which one is better?
Thanks in advance.
exchange data between application
I am writing two applications on windows, one using Eclipse and MinGW and the second one with Visual Basic (visual studio); the two applications should exchange data (just few numbers and text, but frequently, bi-directional) I am very basic developer! anyone could give me very very simple advice? Thank you very much
Preprocessor output on Qt Creator
I am compiling C code in Qt Creator and I need to look at the preprocessor output.
I added the -E flag to the make, but I don't see the *.i files:
mingw32-make.exe -e -w in qtqt-build-desktop
Please help.
setTimout with Javascript for automation
I'm new in Javascript and JXA and I have tried to use a window.setTimeout but I get an error at runtime:
"Error on line 182: TypeError: window.setTimeout is not a function.
(In 'window.setTimeout(function(){
}, 3000)', 'window.setTimeout' is undefined) (-2700)"
can someone help me ?
Turbo c++ stopped working on windows 10 [on hold]
I have a dual booted PC windows 10 along with Ubuntu 15.10,i have been using turbo c++ for a quite long time but today it showed the following error: Windows cannot find 'C:TurboC4Techapple.netDOSBox.exe'. Make sure you typed the name correctly and try again. How to fix this issue?
what is this error in my code?
$db->query("update `state` set `om-id` = '".$statR['om-id']."' where `userid` = '".$_SESSION['userid']."'");
Error:
Query was:
update `state` set `om-id` = '21' where `userid` = '5'
Query Error:
Unknown error 1054
How to check which coupon is applied to which product in WooCommerce?
Since we can apply different coupons to each product in an order,
Is there any method to know which coupon is applied to which product?
I've used $order->get_used_coupons()
function but it just returns the used coupon codes only.
Please help with a solution. Thanks.
How to merge element in looped array if some of the element is in another array?
I have an array like this:
var arr = [
[11, 12, 13, 14],
[1, 2, 3, 4],
[3, 4, 5],
[5, 6, 7, 8],
[6, 7, 8 , 9]
];
I would like to concatenate array that has value in another array and remove its duplicates so in this case it should output:
var arr = [
[11, 12, 13, 14],
[1, 2, 3, 4, 5, 6, 7, 8, 9]
];
Any help would be appreciated. Thank you!
jQuery parsing RSS and namespaced element like <content:encoded>
I am using jQuery to parse an RSS feed. Within each <item>
is a namespaced element like <content:encoded>
I want to select. How do I select it in jQuery?
$(xml).find('item') works but $(xml).find('item content') does not.
while loop with two conditions in c
I have been trying to run this code, but it only works when I use one condition, and leave out the other condition, but I need both conditions to be met simultaneously.
int n;
do
{
printf("numbern");
scanf("%i", &n);
}
while (n < 0 && n > 3)
Set breakpoint in C or C++ code programmatically for gdb on Linux
How can I set a breakpoint in C or C++ code programatically that will work for gdb on Linux?
I.e.:
int main(int argc, char** argv)
{
/* set breakpoint here! */
int a = 3;
a++; /* In gdb> print a; expect result to be 3 */
return 0;
}
jQuery could not get the scroll height of a div element
I was trying to get the height of an element with jQuery but it was returning undefined
Code:
alert($('.forIndex').scrollHeight())
Please any help will be greatly appreciated at: http://www.tulzmasterz.com/tutorials/