-
Posts
75 -
Joined
-
Last visited
Posts posted by ebchost
-
-
I have Not viewed traffic bandwith problem
My maximum bandwith is 4GB
from 01.02.2013 utnhil 24.02.2013 i have
-----------------------------------------------------------
Viewed traffic *
Unique visitors - 1806
Number of visits - 9,345(5.17 visits/visitor)
Pages - 20,552(2.19 Pages/Visit)
Hits - 46,210(4.94 Hits/Visit)
Bandwidth - 1.51 GB (169.16 KB/Visit)
-----------------------------------------------------------
Not viewed traffic *
Pages - 25,578
Hits - 106,869
Bandwidth - 3.31 GB
-----------------------------------------------------------
* Not viewed traffic includes traffic generated by robots, worms, or replies with special HTTP status codes.
From Not viewed traffic, the bigest bandwith take HTTP Status codes part:
"206 Partial Content" - 2.83 GB"
Can you tell me more about this?
Is this problem, and how to fix this ?
-
I understand now what is the problem...
There's nothing wrong with the display, because contains a lot of tags (copy paste from 'View Page source')
$string = "tags, text, <embed youtube link >, ....";
Q: How to get youtube link from $string get youtube link?
-
if wee have
$description =[/color]<strong>Svetaca </strong>na „Mestalji“ u prvom meču osmine finala Lige šampiona, pristalice pariskog kluba su istakle transparent <strong>„Kosovo je Srbija“</strong> na engleskom jeziku, uz srpsku trobojku.</p><p><object classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"425\" height=\"350\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0\"><param name=\"src\" value=\"http://www.youtube.com/watch?v=ri2RXhr4FS8\" /><embed type=\"application/x-shockwave-flash\" width=\"425\" height=\"350\" src=\"http://www.youtube.com/watch?v=ri2RXhr4FS8\"></embed></object></p><p>U pitanju je navijačka grupa <strong>Karsud</strong>, koja sebe smatra ultrasima i nije na dobrom glasu u Francuskoj zbog huliganizma.</p><p>Isti transparent navijači <strong>
How wee can extract only youtube link?
-
if wee have
$description =[/color][font=monospace][size=1]<strong>[/size][/font][color=#000000][font=monospace][size=1]Svetaca [/size][/font][/color][font=monospace][size=1]</strong>[/size][/font][color=#000000][font=monospace][size=1]na „Mestalji“ u prvom meču osmine finala Lige šampiona, pristalice pariskog kluba su istakle transparent [/size][/font][/color][font=monospace][size=1]<strong>[/size][/font][color=#000000][font=monospace][size=1]„Kosovo je Srbija“[/size][/font][/color][font=monospace][size=1]</strong>[/size][/font][color=#000000][font=monospace][size=1] na engleskom jeziku, uz srpsku trobojku.[/size][/font][/color][font=monospace][size=1]</p>[/size][/font][font=monospace][size=1]<p>[/size][/font][font=monospace][size=1]<object classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"425\" height=\"350\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0\">[/size][/font][font=monospace][size=1]<param name=\"src\" value=\"http://www.youtube.com/v/ri2RXhr4FS8\" />[/size][/font][font=monospace][size=1]<embed type=\"application/x-shockwave-flash\" width=\"425\" height=\"350\" src=[url="http://sportskevesti.co/%22http://www.youtube.com/v/ri2RXhr4FS8/%22"]\"http://www.youtube.com/v/ri2RXhr4FS8\"[/url]>[/size][/font][font=monospace][size=1]</embed>[/size][/font][font=monospace][size=1]</object>[/size][/font][font=monospace][size=1]</p>[/size][/font][font=monospace][size=1]<p>[/size][/font][color=#000000][font=monospace][size=1]U pitanju je navijačka grupa [/size][/font][/color][font=monospace][size=1]<strong>[/size][/font][color=#000000][font=monospace][size=1]Karsud[/size][/font][/color][font=monospace][size=1]</strong>[/size][/font][color=#000000][font=monospace][size=1], koja sebe smatra ultrasima i nije na dobrom glasu u Francuskoj zbog huliganizma.[/size][/font][/color][font=monospace][size=1]</p>[/size][/font][font=monospace][size=1]<p>[/size][/font][color=#000000][font=monospace][size=1]Isti transparent navijači [/size][/font][/color][font=monospace][size=1]<strong>[/size][/font][color=#000000][font=monospace][size=1]
How wee can extract only youtube link?
-
How to create left and right background banner like in this example
http://www.cityofnis.rs/index.php/sport
or
or
In this examle left and right sied banner have widht of left and right free space (dinamic width)
how to make it ?
-
Earlier I reported on this forum for help in creating a rss reader
Of course I have successfully solved with the help of people from the forum
Now I would like to go one step further
and now the problem
There are several types of rss news. For Example:
1. Some types such as this one contains a part <content:encoded> that is in itself
http://www.zurnal.rs/category/fudbal/feed?lang=lat
2. Some types, such as this does not include <content:encoded> the part that is in itself
http://www.politika.rs/rubrike/Sport/index.1.lt.xml
this is error when i try to load RSS soruce from number 2
Warning: SimpleXMLElement::xpath() [simplexmlelement.xpath]: xmlXPathEval: evaluation failed in C:\Program Files (x86)\EasyPHP-5.3.9\www\reader.php on line 37this is line:
36 $result = $item->xpath('content:encoded');
37 preg_match('/<img[^>]+>/', $result[0], $match);
38 $item->image = $match[0];
Here is the entire code:
//assigning a rss path to variable $rss = new SimpleXMLElement( 'Link to RSS news' , null, true); //Reading RSS elements, and add values to the variable //hiar is problem about different versions of RSS source foreach($rss->xpath('channel/item') as $item){ $result = $item->xpath('content:encoded'); preg_match('/<img[^>]+>/', $result[0], $match); $item->image = $match[0]; $naslov = mysql_real_escape_string($item->title); $link = mysql_real_escape_string($item->link); $opis = mysql_real_escape_string($item->description); $slika = mysql_real_escape_string($item->image); $datum = date('Y-m-d H:m:s'); $image_object = preg_match_all('/src="(.*?)"/', $result[0], $matches); $image = str_replace( '"','',$matches[0][0]); $imagee = str_replace( 'src=','',$matches[0][0]); echo "$imagee<br><hr>"; //check whether the image is content:encoded area //if image not egsist incontent:encode part, search in the description if($imagee == ""){ $description = $item->description; $descritpion_strip = strip_tags($description); $description_trim = trim($descritpion_strip); $image_object = preg_match_all('/src="(.*?)"/', $description, $matches); $image = str_replace( '"','',$matches[0][0]); $image2 = str_replace( 'src=','',$image); echo $image2; } }
If they somehow managed to distinguish version of RSS news, and I will be able to get around this error
how to achieve it?
PS:
Hiar is result of work with rss news for now.
Thanks for helping to achieve this
-
I trying to display data from a database for editing
I have 2 table:
1. tbl_proizvodi_karakteristike (Translate: tbl_product_caracteristics)
- In this table i have list of product caracteristic relatet to product 'id' in table 'tbl_product_list' (this 'tbl_product_list' is not important now)
- field: id, opis, vrednsot, proizvod_id
2. tbl_karakteristike (Translate: tbl_caracteristic)
- In this table i have list of all caracteristic
- field: id, opis
in field 'opis' in table 'tbl_proizvodi_karakteristike' i insert 'id' from 'tbl_karkateristike' and that works ok with combo box.
But, when i try to edit value in 'tbl_proizvodi_karakteristike', i do not know how to show current value in combo box (i have list of value from 'tbl_karakteristike' in combox, starting from first)
For examle, if i know that value in selected caracteristics is 'opis = 25', it means that i in combo box on load edit form mast have first value 25 and rest of posible value. For now i have value '1 and rest of value'
Hiar is current code in edit form
<form action='product_carasteristic.php?product_id=<?php echo $p_id; ?>&product_name=<?php echo $p_name; ?>' method='POST'> <?php $p_id = $_GET['id']; $karakteristike = mysql_query("SELECT * FROM `tbl_proizvodi_karakteristike` WHERE `id`='$p_id'") or die(mysql_error()); while($row = mysql_fetch_array($karakteristike)){ $p_id = $row['id']; $p_opis = $row['opis']; $p_vrednost = $row['vrednost']; $p_proizvod_id = $row['proizvod_id']; ?> <table> <tr> <td > Karakteristika </td> <td> <select name="opis" style="font-family: verdana; font-size:15px; width:342px;"> <?php $tbl_karakteristike = mysql_query("SELECT * FROM `tbl_karakteristike`") or die(mysql_error()); while($row = mysql_fetch_array($tbl_karakteristike)){ $k_id = $row['id']; $k_opis = $row['opis']; ?> <option value='<?php echo $k_id; ?>'><?php echo $k_opis; ?></option> <?php } ?> </select> </td> </tr> <tr> <td> Vrednost karakteristike </td> <td> <input type="text" name="vrednost" value='<?php echo $p_vrednost; ?>'> </td> </tr> <tr> <td> <input type="submit" name="submit" value="Kreiraj"> </td> <td> Neophodno je popuniti sva polja </td> </tr> </table> <?php } ?> </form>
thanks forward
-
this is solution, but is not exelent
if you see my web page after open it, you will see url like
http://radio-la.info/?r=1&width=1366&Height=768 (if resolution is 1366 x 768)
http://radio-la.info/?r=1&width=1440&Height=900 (if resolution is 1440 * 900)
how to do this, without url ? how to transfer valu from java script to php ? thanks
this is code
<? if(!isset($_GET['r'])) { echo "<script language=\"JavaScript\"> <!-- document.location=\"$PHP_SELF?r=1&width=\"+screen.width+\"&Height=\"+screen.height; //--> </script>"; } else { // Code to be displayed if resolutoin is detected if(isset($_GET['width']) && isset($_GET['Height'])) { // Resolution detected $sir = $_GET['width']; $vis = $_GET['Height']; //echo "width $sir"; $slo = $sir - 986; //echo "<br>"; //echo "free pix width $slo"; //echo "<br>"; $ban = $slo/2; //echo "banner width = $ban"; } else { // Resolution not detected //echo "nema"; } } ?>
-
i think that z-index is not solution
if you look
if z-index is 1 or more, banner go over web page (bouth), if z-index is 0 or lower, i cann not click on banner, i see only picture from left and right side of web page, available for a click
now, is logical to have z-index on bouth div (banner) value 1 or mor
but, how to count widhth of the banner, (now width of banner is 25% the left is z-index:0; right is z-index:1;)
width = free white space from left or right side of web page
thanks
-
This is extra example
http://davidwalsh.name/mootools-drag-drop
but, i need help,
How to organize files
step by step.
index.php
<head> <link rel="stylesheet" href="css/template.css" type="text/css" /> </head> <body> <?php $path = $_SERVER['DOCUMENT_ROOT']; $path .= "/resources/init.php"; include_once($path); $query = "SELECT * FROM `a_sort_test` ORDER BY `sort_order` ASC"; $result = mysql_query($query) or die(mysql_error()); if(mysql_num_rows($result)) { ?> <p>Drag and drop the elements below. The database gets updated on every drop.</p> <div id="message-box"><?php echo $message; ?> Waiting for sortation submission...</div> <form id="dd-form" action="<?php echo $_SERVER['REQUEST_URI']; ?>" method="post"> <p> <input type="checkbox" value="1" name="autoSubmit" id="autoSubmit" <?php if($_POST['autoSubmit']) { echo 'checked="checked"'; } ?> /> <label for="autoSubmit">Automatically submit on drop event</label> </p> <ul id="sortable-list"> <?php $order = array(); while($item = mysql_fetch_assoc($result)) { echo '<li title="',$item['id'],'">',$item['title'],'</li>'; $order[] = $item['id']; } ?> </ul> <br /> <input type="hidden" name="sort_order" id="sort_order" value="<?php echo implode(',',$order); ?>" /> <input type="submit" name="do_submit" value="Submit Sortation" class="button" /> </form> <?php } else { ?> <p>Sorry! There are no items in the system.</p> <?php } ?> </body>
tempalete.css
#sortable-list { padding:0; } #sortable-list li { padding:4px 8px; color:#000; cursor:move; list-style:none; width:500px; background:#ddd; margin:10px 0; border:1px solid #999; } #message-box { background:#fffea1; border:2px solid #fc0; padding:4px 8px; margin:0 0 14px 0; width:500px; }
resolt is hiar:
http://www.sportskevesti.co/component/menadzer/sort.php
but what next with other part of example ?
mootols ? Wer and how?
-
If anyone knows, or see, where can I see the following:
how to capture data (players) with mouse pointer, and put it in the appropriate position (make mysql relation)?
Ehat is this, java, jquery ... ?
-
I try somthing like this, but i have problem
<?php $path = $_SERVER['DOCUMENT_ROOT']; $path .= "/resources/init.php"; include_once($path); $formacije = "SELECT * FROM `man_formacije` ORDER BY `id` ASC"; $rezultati = mysql_query($formacije) or die (mysql_error()); $dropdown = "<select name='formacija'>"; ?> <select> <?php while($row = mysql_fetch_array($rezultati)) { $id = $row['id']; $naziv = $row['naziv']; $meta = $_GET['id']; ?> <option value="<?php echo $id; ?>"><?php echo $naziv; ?></option> <?php } ?> </select> <?php if($meta) { echo "<br> $id"; } else echo "error"; ?>
I have error message, or if i put ($meta = $_GET['id'] part of code, below select (combo box) i have echo 20
how to echo (or get) corect value of selctet data from combo box ?
-
Your kidding aren't you?
i mast write SQL with out ``
thanks
Pardon?
SELECT man_timovi.id, man_timovi.naziv, man_timovi.liga_id, SUM( gold ) , SUM( golg ) , SUM( bodd ) , SUM( bodg ) FROM man_timovi, man_utakmice WHERE man_timovi.liga_id = '1' AND man_timovi.id = man_utakmice.domacin OR man_timovi.id = man_utakmice.gost GROUP BY man_timovi.id ORDER BY SUM( `man_utakmice`.`bodd` + `man_utakmice`.`bodg` ) DESC
the only thing bothering me now is, which is still showing data for the league labeled liga=2, liga=3 .. I want only league 1 (liga_id = 1)
-
Your kidding aren't you?
i mast write SQL with out ``
thanks
-
$utakmice = mysql_query(" SELECT `man_timovi`.`id`, `man_timovi`.`naizv`, `man_timovi`.`user_id`, `man_utakmice`.`id`, `man_utakmice`.`liga_id`, `man_utakmice`.`sezona_id`, `man_utakmice`.`kolo`, `man_utakmice`.`datum, `man_utakmice`.`domacin`, `man_utakmice`.`brojd`, `man_utakmice`.`gold`, `man_utakmice`.`golg`, `man_utakmice`.`brojg`, `man_utakmice`.`gost`, SUM(`man_utakmice`.`bodd` + `man_utakmice`.`bodg`) FROM `man_timovi`,`man_utakmice` WHERE `man_utakmice`.`liga_id`= '1' AND `man_timovi`.`id` = `man_utakmice`.`domacin` OR `man_timovi`.`id`=`man_utakmice`.`gost` GROUP BY `man_timovi`.`id` ORDER BY SUM(`man_utakmice`.`bodd`+`man_utakmice`.`bodg`) DESC") or die(mysql_error()); while($row = mysql_fetch_array($utakmice)) { .. }
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`.`domacin`, `man_utakmice`.`brojd`, `man_utakmice`.`gold`, `man_utakmice`.`g' at line 9man_timovi:id, liga_id, naziv, user_id berger, sifra
man_utakmice:id, liga_id, sezona_id, kolo, datum, domacin, brojd, gold , golg, brojg, gost, bodd, bodg
-
I try to make Soccer manager, and i have problem to make fixtures by the automaticly rules of Berger tables as shown in table in botom of this post
I have 10 clubs in the N number of Ligue in table man_timovi
------------------------
| id | name | ligue |
------------------------
| 1 | Club1 | 1 |
| 2 | Club2 | 1 |
| 3 | Club3 | 1 |
|....
|10 | Club10 | 1 |
| 11 | Club11 | 2 |
| 12 | Club12 | 2 |
| 13 | Club13 | 2 |
|....
|20 | Club.20 | 2 |
|...
----------------------
By the Berger rules, first, second.... round is like this:
-------------------------------------------
| Round | Ligue | GAME |
--------------------------------------------
Round 1 | Ligue 1 | ID1 vs ID10
Round 1 | Ligue 1 | ID2 vs ID9
Round 1 | Ligue 1 | ID3 vs ID8
Round 1 | Ligue 1 | ID4 vs ID7
Round 1 | Ligue 1 | ID5 vs ID6
Round 1 | Ligue 2 | ID11 vs ID20
Round 1 | Ligue 2 | ID12 vs ID19
Round 1 | Ligue 2 | ID13 vs ID18
Round 1 | Ligue 2 | ID14 vs ID17
Round 1 | Ligue 2 | ID15 vs ID16
.... etc (depends on the number of leagues, each league is played for 18 rounds)
------------------------------------------------------------------------------------------------------
How to make code, with Berger table combiantion ruls?
Manual, game by game is no good, What if wee have more then 1000 ligue in manager?
Thanks
BERGER TABLES FOR 10 CLUBS in halfseson
--------------------------------------
R| G1 | G2 | G3 | G4 | G5
-------------------------------------
1 | 1-10 | 2-9 | 3-8 | 4-7 | 5-6
2 | 10-6 | 7-5 | 8-4 | 9-3 | 1-2
3 | 2-10 | 3-1 | 4-9 | 5-8 | 6-7
4 | 10-7 | 8-6 | 9-5 | 1-4 | 2-3
5 | 3-10 | 4-2 | 5-1 | 6-9 | 7-8
6 | 10-8 | 9-7 | 1-6 | 2-5 | 3-4
7 | 4-10 | 5-3 | 6-2 | 7-1 | 8-9
8 | 10-9 | 1-8 | 2-7 | 3-6 | 4-5
9 | 5-10 | 6-4 | 7-3 | 8-2 | 9-1
-------------------------------------
R is Round, G1,G2, G3, G4, G5 is number of the game
-
$faktura_u_s = mysql_query(" SELECT `tbl_roba_stanje`.`cena`-((`tbl_roba_stanje`.`cena`/100)*`tbl_roba_stanje`.`rabat_proc`) as `cena_bez`, `tbl_roba_stanje`.`ulaz`, (`cena_bez` * `tbl_roba_stanje`.`ulaz` ) AS `osnovica` FROM `tbl_roba`,`tbl_roba_stanje` WHERE `tbl_roba`.`id` = `tbl_roba_stanje`.`roba_id` AND `tbl_roba_stanje`.`dokument_id` = '$dokument'") or die(mysql_error());
and error is " Unknown column 'cena_bez' in 'field list' "
Problem is ?
-
Close, but not quite.
$date = strtotime( '2011/06/05' );
$new = date( 'Y/m/d', $date + (60*60*24*15) );
thanks for this code, that solved my problem
$date = strtotime($date); $new = date( 'Y/m/d', $date + (60*60*24*$days) );
-
if the date of selling goods " $date = "2011/06/05"; and if we have payment after of $days = "15"; - (15 days), how to calculate when the last day for payment?
-
<div style='width: 603px; float:left; border-style: solid; border-width: 0px 1px 1px 1px;'> <div style='width: 30px; padding: 5px 10px 5px 10px; float: left; border-style: solid; border-width: 0px 1px 0px 0px; text-align:left; '><?php echo $i; ?></a></div> <div style='width:330px; padding: 5px 10px 5px 10px; float: left; border-style: solid; border-width: 0px 1px 0px 0px; text-align:left; '><?php echo "$sta_svrha_placanja <br> $sta_referenca <br> $sta_zaduzenje - $sta_odobrenje <br>"; ?></a></div> <div style='width: 80px; padding: 5px 10px 5px 10px; float: left; border-style: solid; border-width: 0px 1px 0px 0px; text-align:right; '><?php echo $sta_duguje; ?></a></div> <div style='width: 80px; padding: 5px 10px 5px 10px; float: left; border-style: solid; border-width: 0px 0px 0px 0px; text-align:right; '><?php echo $sta_potrazuje; ?></a></div> </div>
-
-
You should only store the user-specific data in the session. You shouldn't use sessions to carry dynamic information - that's not what they were designed for.
ok, thanks
What you recomand for this? (because they secretly want to keep inforamicije such as id, etc.)
-
-
a brief description of what I want to do
1. I made a login session, and works without any problems.2. Any user who logs on to the site, after logging, see the list of programs that create and use the site.
3. Choosing one of the program, which belong to login user, the user can view a list of: payments, invoices, statements, statements that belong only to him within a given program
Problem in 3:
I do not want to give for users of applications the ability to see in the link (for examle "index.php?option=programs&userid=1&programs=2") with data such as id, username, or something similar. So I try to do all over the session as in the code below:
list of program for active session - programs.php
<?php session_start(); //takes on a value for the logged in user id in the session $indentifikacija = $_SESSION['id']; $path = $_SERVER['DOCUMENT_ROOT']; $path .= "/knjige/resources/init.php"; include_once($path); $programi = mysql_query("SELECT * FROM `tbl_programi` WHERE `user_id`='$indentifikacija'") or die(mysql_error()); while($row = mysql_fetch_assoc($programi)) { $idprg = $row['idprg']; $program = $row['program']; $user_id = $row['user_id']; $datum = $row['datum']; echo " $idprg"; ?> <a href='/knjige/modules/mod_izvodi/'> <?php echo " $program" ; //taking the value of a variable that contains the session id of program $_SESSION['idprg']=$idprg ?> </a> <?php echo " $user_id"; echo " $datum"; } ?>
//taking the value of a variable that contains the session id of program
$_SESSION['idprg']=$idprg
When I in this application click on a program in the list, for the list of documents in selected programe, code always open a list of documents for the last program (the value of the last variable $idprg)
Q1: Is it possible to do something like this
Q2: If it is possible, where I am wrong, and how to perform
thanks
Not viewed traffic bandwith problem
in Website Critique
Posted
Thanks for the reply
I doubt something else, so help me understand.
http://sportskevesti.co
this is my web page
This web page work on next task:
1. colect xml data (short news)
2. insert or update title, link of source, description, and image, date...
3. show this data at frontape, as short news with image and with link to original source. Sometimes news takes in description embed code of the video
i have 35 Sport news source, 1 currency exchange, 1 wether, and 1 new (live score with 250 game average per day
Can geting and importing data from this source`s can be part of Not viewed traffic * ?