Jump to content

turkman

Members
  • Posts

    154
  • Joined

  • Last visited

    Never

Everything posted by turkman

  1. Im not sure the standard way of doing it. I mean would you create a seperate function for each of the seperate divs? what i imagine that way to be is, Is that the stanard way of doing it? <span id = 'pace_value'>10</span> <a href = 'javascript:updatePace()'> <img src = "plus.gif"></a> <span id = 'Shooting_value'>10</span> <a href = 'javascript:updateShooting()'> <img src = "plus.gif"></a> <span id = 'Tackling_value'>10</span> <a href = 'javascript:updateTackling()'> <img src = "plus.gif"></a>
  2. I want to have a table or divs, each table or div has a number and a plus and minus button. The amount of rows in the table or div can change. If you press a plus the number goes up and a minus makes the number go down. It seems like a waiste to make the jquery update all the divs or table rows for the sake of updating 1 number. But it seems overly complex to give them all a unique div id and only have that single div updated when the plus is clicked. Whats the standard way of doing this example layout Pace: 10 + - Shooting: 12 + - Control: 5 + - Rather than having the whole table printed by the ajax call, is there a way to update just the number in the row of the + or - clicked Hope that makes sense.
  3. i can host it online if you want, give me a sec. http://www.imgboard.co.uk/stupid_css/
  4. Ive tried lots of different fonts, with and without quotes. Im hosting it on my ubuntu apache server, whats really weird is that font-family works on other sites i have store on it i.e var/www/site1 - works var/www/site2 does not work ive been trying to get firbug to work, but it wont show up when i install it. I have tried troubleshooting it, but cant figure out whats wrong with it. I have web developer, but not sure if that can be used. Also ive tried adding font-family into the divs, does not work there either.
  5. Have this very basic css page and a very basic html page, however font-family isnt working in the body bracket. No matter what i change it too, the text remains the same. If i add monospace on the end, the text becomes monospaced and all the other styles work ok, its just not the font-family. I have no idea why. a{ color:#0099CC; } #notice_bar{ background-color: #2088B2; padding: 20px; color: #FFFFFF; } #notice_bar a{ font-weight: bold; color: #006699; } #page_wrapper{ width: 100%; margin: 20px; } #page_header{ height: 50px; font-size: 20pt; text-align: center; } #left_side{ width: 20%; padding: 10px; float: left; } #middle_bit{ width: 60%; padding: 10px; float: left } #right_side{ width: auto; padding: 10px; float: left; } body{ color: #555555; font-size: 9pt; font-family: "Verdana"; }
  6. I made a bot, that scrapes content from a forum, i cant access the forum in work, so am trying to make something discreat to read it on my own site while at work. Anyway the links to threads are something like this. I got help and i know how to extract the unique thread number using regex. However i have a problem. What i really need, now that i think about it, is a way of getting the thread number and the thread title (so i can make sense of what im reading.) The thread title is in the setWindowStatus function. I cant think of a way to do it. I dont even know if it would work in an array what id basically like is something that says 1) Thread title - Thread id 2) Thread title - Thread id etc that is stored in a way that i can easily manipulate. <img src="http://s2.images.proboards.com/xx.gif" alt=" " border="0"/></font></td><td class="windowbg" bgcolor="FFFFFF" width="48%" style="cursor:pointer;" onClick="if(!pb_bubble)location.href='/index.cgi?board=general&action=display&thread=13483';" onMouseOver="mouseOverHighlightCell(this);setWindowStatus('Lurkers, show your face ');return true;
  7. using curl, ive managed to get my program to log me into a proboards site. I can view the main forum page. The problem is, the links to viewing the page is something like href="index.cgi?board=general&thread=1111&page=45" I did a str_replace to replace the index.cgi to href= "link_processor?board=general&thread=1111&page=45" The idea was that link_processor would contain the data "board=general&thread=1111&page=45" However, i now realise that the way the php would see that as 4 different get variables link processor = board=general thread = 1111 page = 45 How could i make it all part of the link_processor variable because if i can keep the string intact, i just have to pass it to a curl function and i can display the page easily!
  8. In the source of a webpage, i have lots of data including about 40 lines similar to this. I want to extract the number of &thread= each time this line appears and store them all in an array. onClick="if(!pb_bubble)location.href='/index.cgi?board=general&action=display&thread=13377';
  9. I got it working anyway. I still have a small problem. I used HTTP live headers firefox extension to capture the headers when i start a thread. I brings back something like this -----------------------------12249266671528 Content-Disposition: form-data; name="title" Filme 2010, filme 2009, filme noi, programe TV, program cinema, premiere cinema, trailere filme - CineMagia.ro -----------------------------12249266671528 Content-Disposition: form-data; name="category" 3 -----------------------------12249266671528 Content-Disposition: form-data; name="tags" filme, programe tv, program cinema -----------------------------12249266671528 Content-Disposition: form-data; name="bodytext" Filme 2010, filme 2009, filme noi, programe TV, program cinema, premiere cinema, trailere filme -----------------------------12249266671528 Content-Disposition: form-data; name="trackback" -----------------------------12249266671528 Content-Disposition: form-data; name="url" http://cinemagia.ro -----------------------------12249266671528 Content-Disposition: form-data; name="phase" 2 -----------------------------12249266671528 Content-Disposition: form-data; name="randkey" 9510520 -----------------------------12249266671528 Content-Disposition: form-data; name="id" 17753 -----------------------------12249266671528-- how do you use curl to post data like that? Usually i just use name=blah&message=blah i dont know how to emulate this Content disposition stuff.
  10. There is a proboards site i like to visit. However, its been blocked at my work. I was trying to find a way of logging into it via my site and using that to read the proboards site. I dont really need to post or anything, just something to read when i get bored. I want to keep the name of the site secret. However this is my code. Note: When i run the code i get a blank page. Nothing at all happens. <?PHP function login($website,$username,$password){ $post_data = array( "action" => "login2", "minutes" => "-1", "username" => $username, "password" => $password, ) Post_thread($website,$post_data); } function Post_thread($url,$post_data){ $options = array( CURLOPT_COOKIEJAR => "/tmp/cookies.txt", // where we store the cookie. CURLOPT_COOKIEFILE => "/tmp/cookies.txt", // to pass the cookie if we need too. CURLOPT_RETURNTRANSFER => true, // return web page CURLOPT_HEADER => false, // don't return headers CURLOPT_FOLLOWLOCATION => true, // follow redirects CURLOPT_ENCODING => "", // handle all encodings CURLOPT_USERAGENT => "spider", // who am i CURLOPT_AUTOREFERER => true, // set referer on redirect //CURLOPT_REFERER => $url, //spoof the referer CURLOPT_CONNECTTIMEOUT => 120, // timeout on connect CURLOPT_TIMEOUT => 120, // timeout on response CURLOPT_MAXREDIRS => 10, // stop after 10 redirects CURLOPT_POST => true, // we want to post some data CURLOPT_POSTFIELDS => $post_data, //array of what we want to post ); $ch = curl_init( $url ); curl_setopt_array( $ch, $options ); $content = curl_exec( $ch ); echo $content; $errmsg = curl_error( $ch ); echo $errmsg; } login("http://randomproboardssite.proboards.com","username","secretpassword"); ?>
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.