I have a string of the form "a-b""c-d""e-f"...
Using preg_match, how could I extract them and get an array as:
Array
(
[0] =>a-b
[1] =>c-d
[2] =>e-f
...
[n-times] =>xx-zz
)
Thanks
Hello,
i think the fullcalendar jquery-plugin is a really great solution.
i saw does the string for the title in the fullcalender plugin is escaped (htmlEscape). But i need to format some strings in the title for example bold text or colors, or small images?
the solution with another plugin (for example qTip, like in the examples) will not the right way for me.
is there anyway to format the title text?
Regards
flauschi
Hi All,
i am trying to figure out how to write a linq query that will return a child collections "name" property as a string.
I have a BO that has a "options" property where the options are the "name" property of each option in an "order" object.
I would like the result to look something like
order.id = 12312
order.date = 12/03/10
order.options = "Option 1 Name, Option 2 Name, Option 3 Name"
I hope this makes sense. thanks for any and all help!
How do I restrict a string to whitelisted characters?
// "HOW am I to understand; this is, BAD"
$str = restrictTo($str,"0-9a-z,. ");
// " am I to understand this is, "
Is there an inbuilt function in PHP that does something close? I can't formulate a regular expression for this though :(
If I have an array named $myArray how can I get a reference to it from a string of the same name myArray. I tried:
eval('myArray');
But that gave me an error.
Hi everyone,
I am in the middle of building a cache layer for the Redis DB to my application and I have come to the point where's it's about to take care of arrays.
I wonder if there's any good (high performance!) way of controlling an string to be serialized or not with PHP?
Thanks a lot!
I am trying to check if a lhs is already abbreviated in vim.
mapcheck, however, seems to have a problem. For example,
iabbr swt switch
echo mapcheck('sw','i',1)
returns "switch" even when "switch" defined for "swt".
mapargs seem to return a string even if there is a partial
match with the lhs. Is there a way to find if an
abbreviation has been defined for the "exact" match, i.e.,
the above mapcheck returning a "" instead.
I'd like to test whether a string contains "Kansas" followed by anything other than " State".
Examples:
"I am from Kansas" true
"Kansas State is great" false
"Kansas is a state" true
"Kansas Kansas State" true
"KansasState" true
(For my immediate purposes this should work with mysql's REGEXP but if there's a more elegant way using PCRE, I'd like to see that too.)
Hello,
I am writing a piece of code in which i have to find only complete words for example if i have
String str = "today is tuesday";
and i am searching for "t" then i should not find any word.
Can anybody tell how can i write such a program in java?
I am using Convert.ToInt32(ddlBuyer1Country.SelectedValue); to typecast a string returned by selectedvalue.
But this is giving me 0 instead of 3. I have selected value as 3 in this case.
Trying to find a way to trim spaces from the start and end of the string. I was using this, but it dont seem to be working:
title = title.replace(/(^[\s]+|[\s]+$)/g, '');
Any ideas?
I'm trying to use sed to replace whitespace within a string. For example, given the line:
var test = 'Some test text here.';
I want to get:
var test = 'Sometesttexthere.';
I've tried using (\x27 matches the '):
sed 's|\x27\([^x27[:space:]]*\)[[:space:]]|\x27\1|g
but that just gives
var test = 'Sometest text here.';
Any ideas?
I have 300 boolean fields in one table, and im trying to do somithing like that:
One string field:
10000010000100100100100100010001
Ha a simple way to do a simple search os this field like:
select * from table where field xor "10000010000100100100000000010001"
Im tring this but is to long:
select * from teste where mid(info,2,1) and mid(info,3,1)
:) Help!!
I have:
tXML = "<type p_type=\"All\"/>";
if I do
Response.Write(tXML);
I get a blank space.
Is there anyway to output this string so I know it is being created?
I am creating a secure web based API that uses HTTPS however if I allow the users to configure it (include sending password) using a query string will this also be secure or should I force it to be done via a POST?
Hi-- I have a UK date in the format "06/Apr/2010 13:24" that I need to insert into a mysql db date field.
The PHP strtotime function can't handle this string-- has anyone got any ideas other than writing a custom function?
Thanks!
What could be the easiest way to match all links and e-mail addresses in a string to a list array? I was using preg_match in PHP but in C# it looks like it will be way different.
Hi guys, i've this string example value:
Sun, 09 May 2010 11:16:35 +0200
I've to insert it into MySql Date/Time field.
How can i convert it into .NET format (or Mysql format), so i can make my INSERT INTO mydate='2010-05-09 11:16:35' ?
Thank you !