Sep 1

jqGrid is an Ajax-enabled JavaScript control that provides solutions for representing and manipulating tabular data on the web. Since the grid is a client-side solution loading data dynamically through Ajax callbacks, it can be integrated with any server-side technology, including PHP, ASP, Java Servlets, JSP, ColdFusion, and Perl.

jqGrid’s Home page can be found here

Jul 5

un plugin foarte bun de jQuery, care permite uploadarea multipla de fisiere doar cu drag and drop

sursa aici

Jun 1

Excel interpreteaza < br > ca fiind un rand now, ca sa evitam aceasta problema si sa adaugam o linie noua in celula in MS Excel trebuie adaugat un CSS pentru break

< style >
br {mso-data-placement:same-cell;}
< / style >

May 17

Internet Explorer gives lower level of trust to IFRAME pages (IE calls this “third-party” content). If the page inside the IFRAME doesn’t have a Privacy Policy, its cookies are blocked.

However if you add  a header like this (in PHP) it will work:

header(‘P3P:CP=”NOI CURa ADMa DEVa TAIa OUR BUS IND UNI COM NAV INT”‘);

This sets a  P3P header with a privacy policy that is acceptable to IE, and the cookies will be accepted.

More info: here and here.

A tool for generating policy privacy can be downloaded here.

Mar 24

If you have in ASP.NET a textbox with property readonly=true or enabled=false then on postback it will lose its value. To prevent this, instead of making the textbox readonly using properties option, write in the server code
TextBox1.Attributes.Add(“readonly”, “readonly”);
That will still make the textbox readonly and will also retain the value after each postback.

Mar 17

If not a bug in your current distribution then just go to Content Assist preferences in:
Windows/Preferences/Java/Editor/Content Assist/Advanced and press “Restore Defaults” or check the option “Java Proposals”.

Jan 25

DECLARE @name VARCHAR(50) — database name
DECLARE @path VARCHAR(256) — path for backup files
DECLARE @fileName VARCHAR(256) — filename for backup
DECLARE @fileDate VARCHAR(20) — used for file name

SET @path = ‘C:\backup\’

SELECT @fileDate = CONVERT(VARCHAR(20),GETDATE(),112)

DECLARE db_cursor CURSOR FOR
SELECT name
FROM master.dbo.sysdatabases
WHERE name NOT IN (‘master’,'model’,'msdb’,'tempdb’)

OPEN db_cursor
FETCH NEXT FROM db_cursor INTO @name

WHILE @@FETCH_STATUS = 0
BEGIN
SET @fileName = @path + @name + ‘_’ + @fileDate + ‘.BAK’
BACKUP DATABASE @name TO DISK = @fileName
–SELECT @fileName
FETCH NEXT FROM db_cursor INTO @name
END

CLOSE db_cursor
DEALLOCATE db_cursor

sursa

Dec 6

This guide aims to familiarize you with some of the basic concepts of online security and teach you how to write more secure PHP scripts.

http://php.robm.me.uk/

Nov 17

Control Panel / System and security / Windows Firewall / Advanced settings / Inbound rules / New rule –> Custom rule

At Protocol and ports: select Protocol: ICMPv4 then go to customize and choose “Specific ICMP types” and check the box “echo request”.

Next / Next / …

May 3

Exemple de generare categoriilor ierarhic din SQL

exemplu:

LOCK TABLE nested_category WRITE;

SELECT @myRight := rgt FROM nested_category
WHERE name = ‘TELEVISIONS’;

UPDATE nested_category SET rgt = rgt + 2 WHERE rgt > @myRight;
UPDATE nested_category SET lft = lft + 2 WHERE lft > @myRight;

INSERT INTO nested_category(name, lft, rgt) VALUES(‘GAME CONSOLES’, @myRight + 1, @myRight + 2);

UNLOCK TABLES;

SELECT CONCAT( REPEAT(‘ ‘, COUNT(parent.name) – 1), node.name) AS name
FROM nested_category AS node,
nested_category AS parent
WHERE node.lft BETWEEN parent.lft AND parent.rgt
GROUP BY node.name
ORDER BY node.lft;

+———————–+
| name |
+———————–+
| ELECTRONICS |
| -TELEVISIONS |
| – -TUBE |
| – -LCD |
| – -PLASMA |
| -PORTABLE ELECTRONICS |
| – -MP3 PLAYERS |
| – -FLASH |
| –CD PLAYERS |
| –2 WAY RADIOS |
+———————–+

Soursa: aici

« Previous Entries Next Entries »

Powered By Wordpress - Theme Provided By Wordpress Theme - Credit Loan