l2topzone.com
l2topzone.com

Author Topic: [HELP]Vote Reward Problem  (Read 1637 times)

0 Members and 1 Guest are viewing this topic.

Offlinedisorder25

  • Newbie
  • *
  • Posts: 47
  • L2topzone Votes: 3
  • Servers reviews: 0
  • Country: United States.
  • Reputation: +114/-0
  • Gender: Male
    • L2 Obsessed PVP Server
[HELP]Vote Reward Problem
« on: March 18, 2014, 09:46:54 AM »
l2topzone.com
Can you help me fix this script?

Code: [Select]
public int getVotes()
{
URL url = null;
InputStreamReader isr = null;
BufferedReader in = null;
try
{
url = new URL(http);
URLConnection con = url.openConnection();
con.addRequestProperty("User-Agent", "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:10.0.2) Gecko/20100101 Firefox/10.0.2");
isr = new InputStreamReader(url.openStream());
in = new BufferedReader(isr);
String inputLine;
while ((inputLine = in.readLine()) != null)
{
// for top-zone
if (inputLine.contains("Votes:"))
{
return Integer.valueOf(inputLine.split(">")[3].replace("</div", ""));
}
}


Linkback: https://l2topzone.com/forum/l2-server-support-problems/9/helpvote-reward-problem/18042/

OfflineiVersion

  • Jr. Member
  • **
  • Posts: 52
  • L2topzone Votes: 24
  • Servers reviews: 0
  • Country: Greece.
  • Reputation: +0/-0
  • L2J Interlude Dev

    OfflineGraetMaestro

    • Global Moderator
    • Hero Member
    • *****
    • Posts: 520
    • L2topzone Votes: 0
    • Servers reviews: 0
    • Country: Portugal.
    • Reputation: +57/-0
      Re: [HELP]Vote Reward Problem
      « Reply #2 on: March 18, 2014, 12:58:15 PM »
      hello
      or try check  this this last post from  administrator  xzone ...http://l2topzone.com/forum/announcements-and-news/fix-for-voterewards/
      Read the Forum Rules...use the correct section... read  the section rules before post...Post clear your Topics and like say in the rules..check before if existe a Topic don't open new topics..bump after  the 24 houres...Don't use the EDIT to bump legaly your topic  because is not (after a few minutes +/- 20, the EDIT is considered a BUMP)....  dont forget  your server website link .... respect all users.


      Share via diggShare via facebookShare via linkedinShare via myspaceShare via redditShare via twitter
       


      Sitemap