Website Toolbox Pro

What Does “Javascript”, “Dreamweaver”, “CSS” Mean And How Does It All Fit Together?

Javascript, Miscellaneous, PHP / MySQL Comments »
I’m new to this whole thing, I need to know for journalism class please!

How does HTML, CSS, Python, Dreamweaver, InDesign, PHP…. what do these things have to do with websites?

Continue reading What Does “Javascript”, “Dreamweaver”, “CSS” Mean And How Does It All Fit Together? »

Struggling With Perl Regular Expression

Regular Expressions Comments »
I have a series of words followed by a pre-determined marker (say the letter x in this case) contained in a string.

$contents = 'test1x     test!x     test2x';

There is a need to extract a list of those words that contain only alphanumeric characters plus the marker, ‘x’. So obviously “test!x” not wanted.

If I run the following regex:

@filtered_list =
(
  $contents =~  /(?:[\w]+) /g
);

Then I get the following list returned:

("test1x", "x", "test2x")

as opposed to a required list of

("test1x", "test2x")

The problem is with the 2nd item – it fails on the character “!” and just moves on to the next character when I really want to just stop right there and not return anything for this word.

I know I am just not seeing something completely obvious…

Thank you.

Continue reading Struggling With Perl Regular Expression »