Mode used in languages such as Javascript and Perl to be able to code with a restricted version of those languages.
Questions tagged [strict]
490 questions
0
votes
1 answer
Perl - Webmin - "strict refs" in use
I have a problem with module for Webmin, and I just want to resolve it with your help!
This is error that I get when I try do add new VirtualHost to Nginx module:
Error - Perl execution failed
Can't use string ("/home/www/website") as an ARRAY ref…

Steffffan
- 27
- 1
0
votes
2 answers
str_replace string and similar string
I'm trying to use the str_replace() function with an array of strings.
My problem is that some strings in my array contains another string.
Here is an example:
I have a category of products such as:
$product1 = 'COLLIERPEND';
$product2 =…

FLX
- 2,626
- 4
- 26
- 57
0
votes
2 answers
Strict Standards: Only variables should be passed by reference in array
$name = substr($name, 0, -strlen($ext)) . "_medium." . end(explode('.',$name));
the above code report strick standard warning, the small script as below:
function medium($name) {
$ext = strrchr($name, '.');
if($ext !== false) {
…

jones
- 631
- 3
- 9
- 20
0
votes
3 answers
Strict comparaison between char and int
I would like to know if it was possible to compare an integer and a char.
Something that could be the "===" from Javascript.
Because
'a' == 97
Will ouput
1
Edit : I would like something like
compare('a', 97)
Which would ouput
0
How i can do…

Extaze
- 1,117
- 2
- 10
- 18
0
votes
2 answers
Strict Standards: Non-static method (joomla and roksprocket)
Strict Standards: Non-static method K2ModelItemlist::getCategoryTree() should not be called statically, assuming $this from incompatible context in C:\xampp\htdocs\virgin\components\com_roksprocket\lib\RokSprocket\Provider\K2\Filter.php on line 151…

Hello Universe
- 3,248
- 7
- 50
- 86
0
votes
1 answer
Ideas on an alternative to the
doing a project at uni and I've completely misread the brief, used HTML5 in my project and realised that I'm not allowed to do this. Oops!
My only problem is, I've tried to convert it to XHTML Strict 1.0 standards by using divs and it just isn't as…

iXiiN
- 15
- 1
- 4
0
votes
2 answers
The three-column layout conundrum, this time sans header and footer
I know this is one of those Web 1.0 newbie questions, but alas, I am in a position to be asking it myself. I do sites that do not necessitate this sort of layout and am now looking at doing one for a friend with a three-column layout, fixed-width…

mileaminute
- 113
- 1
- 8
0
votes
1 answer
make YAJL throw an exception on malformed JSON
Yajl.load does not always throw on parse errors. For example:
irb(main):004:0> Yajl.load('[[],"NOOOOOOOOOOOoooooooooooo!')
=> [[]]
It just ignored that tiny little detail at the end, and continues with what it got to that point. I want it to…

Geremy
- 2,415
- 1
- 23
- 27
0
votes
2 answers
Unable to turn off strict standards warnings, XAMMP, PHP 5.4.7
I'm trying to get some third-party PHP software to run on Windows (it runs on Ubuntu).
I'm using XAMMP with Apache/2.4.3, PHP/5.4.7
The php.ini file, C:\xampp\php\php.ini, is set to not report strict warnings as shown below:
error_reporting =…

Jack BeNimble
- 35,733
- 41
- 130
- 213
0
votes
1 answer
Simple JavaScript Inheritence plugin error
I read John Resig's blog article on a Simple JavaScript Inheritance plugin that he wrote based on base2 and prototype.
Example code is here: http://jsfiddle.net/rFfX9/
//'use strict';
/* Simple JavaScript Inheritance
* By John Resig…

Greg
- 31,180
- 18
- 65
- 85
0
votes
1 answer
PHP - E_STRICT: Creating default object from empty value
I see there are about a hundred different questions on here for Creating default object from empty value. None of them really seem to help with my issue.
I am assigning a child object of the same class in a method. This triggers the Creating default…

teynon
- 7,540
- 10
- 63
- 106
0
votes
3 answers
Code Fragment: is this pure C?
I've got following code fragment and I want to know if it is pure C or it contains some C++ elements. This question stems from the fact that I think it is only C, but some compilers don't accept the code.
// User struct derived from…

Tommaso DS
- 211
- 2
- 14
0
votes
1 answer
how to get javascript to not rounding a number with 0 decimal to a whole number
Is there a way to get JS to not round a number with a 0 decimal to a whole number? ex var = 100.0 //100? I know this isn't a regular thing to do in JS but it's needed to port a method from a processing library which im porting to processing.js. the…

Jisike
- 383
- 1
- 3
- 11
0
votes
6 answers
How to find and print a line with a strict pattern is appropriate
The problem is as follows. There is a file with a set of strings
testfile:
string2 var var33
string2 HD loop 334
000:000:7878:7878:8978
string1 var var33
string1 HD loop
000:000:7878:7878:8978
string3 var var33
string3 HD…

Alex
- 41
- 1
- 5
0
votes
1 answer
Restrict interface to specific classes or restrict a property/declare to specific class+interface
I have an Interface IDataControl:
public interface IDataControl
{
...
}
Then, I have a class with a variable of List.
List items;
The problem is when I try to add elements of this collection in a "Controls"…

HOO
- 1