The code by Kirsle (Programmer) works perfectly
for me. Thanks a lot.
Thanks a lot for all others as well specially for KevinADC as I found him very helpful all the time.
I have versy simple data like
1
2
5
6
2
8
9
10
1
3
200
50
3
2
1
Out of these I want to list each unique value and its frequency i.e how many time it is in the data
e.g
2 is found 3 time
50 is found 1 time
200 is found 1 time
The expected result should be like that
this is chain A
this is chain B
this is chain C
this is chain D
this is Chain F
but I am getting out put like this
this is chain A
this is chain A
this is chain B
this is chain B
this is chain B
this is chain B
this is chain C
this is chain D...
my code is as follow
open (SP, "myfile");
my $chains;
my @chains;
while(<SP>){
if ($_=~/^COMPND\s+\d+\sCHAIN:\s(.)/){
$chains=$1;
print "$chains";
}
}
the result print out
A K Y T C D E F values for...
I have a data like this
SEQRES 1 A 1522 U U U G U U G G A G A G U
SEQRES 2 A 1522 U U G A U C C U G G C U C
SEQRES 3 B 1522 A G G G U G A A C G C U G
SEQRES 4 B 1522 G C...
I want to extract the windows media player streaming from this URL
http://desimadesi.webhop.org/pak%20Channels/playmovies.php?mid=46
I can curl the whole page. But there is some problem with preg match statement
Here is my complete code. I want to fetch the media player streaming from the page.
I have tried again but this is still not working.
<?php
// create a new curl resource
$ch = curl_init();
// set URL and other appropriate options
curl_setopt($ch, CURLOPT_URL...
I have updated my code as
<?php
// create a new curl resource
$ch = curl_init();
// set URL and other appropriate options
curl_setopt($ch, CURLOPT_URL, "URL.COM");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
// grab URL, and return output
$output = curl_exec($ch);
// close curl...
I want to curl a page and extract data between a div tag
<div class="topmasters" align="center"> data required </div>
here is my code
// create a new curl resource
$ch = curl_init();
// set URL and other appropriate options
curl_setopt($ch, CURLOPT_URL, "http://example.com/")...
I want to display some of contents from my one website to an other one live.
I am planing using cURL for this job.
Here is my code for this task
<?php
// create a new curl resource
$ch = curl_init();
// set URL and other appropriate options
curl_setopt($ch, CURLOPT_URL...
Dear barneyblackburn, Can you give a try to ASCII code instead of usin £ symbol if the problem persist?
I tried this
[code]
#!/usr/bin/perl -w
my $pound = "testing £ stuff here";
$pound =~ s/£/£/g;
print "FOO: $pound";
[/cod]
on my local suse 10.2 installation and it...
Dear All,
I am not saying any body to write the full script for me. Well I know that I can use notepad, kwrite, vi, etc for writing a php script.
I just want a start how to use IP redirection in PHP. I am new to PHP .
Otherwise please tell me some books/chapter to read for this.
Regards
Yes
I want to show different sites to people coming from different IP locations.
i.e different site/contents for users coming from Pakistan, UK, USA and Germany etc.
Regards
Thanks,
(/^ATOM\s+\S+\s+\S+\s+\S+\s+\S\s+(10|11|12|13|14|18|31|33|64|80|81|82|83|84|85|86|89|129|131|132|134|144|145)\s/)
can in the above line we pick values from 10,11,12, 13, 18 etc from an external file or from an array
i.e the external file could be a simple file containing these...
Dear All
I have a code written in PERL. It is a working code for me.
But i want to rewrite it to make it a bit short and more scientific.
I have a similar task which is repeated again and again like in if else you can see the matching statements are also most similar except the number at...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.