is there any trick to run a Webservice automatically to check some date specific and performs some operations on particular date. like sending birthday email's and so on ?
Hello stackoverflow,
I'm a "long time reader first time poster", glad to start participating in this forum.
My experience is with Java, Python, and several audio programming languages; I'm quite new to the big bad web technologies: HTML/CSS/JavaScript. I'm making two personal sites right now and am wondering if I'm relying on JavaScript too much.
I'm making a site where all pages have a bit of markup in common--stuff like the nav bar and some sliced background images--so I thought I'd make a pageInit() function to insert the majority of the HTML for me. This way if I make a change later, I just change the script rather than all the pages. I figure if users are paranoid enough to have JavaScript turned off, I'll give them an alert or something. Is this bad practice? Can JavaScript be overused?
Thanks in advance.
Sorry this got long and all prose-y. I'm creating my first truly gamified web app and could use some help thinking about how to structure the data.
The Set-up
Users need to accomplish tasks in each of several categories before they can move up a level. I've got my Users, Tasks, and Categories tables, and a UserTasks table which joins the three. ("User 3 has added Task 42 in Category 8. Now they've completed it.") That's all fine and working wonderfully.
The Challenge
I'm not sure of the best way to track the progress in the individual categories toward each level. The "business" rules are:
You have to achieve a certain number of points in each category to move up.
If you get the number of points needed in Cat 8, but still have other work to do to complete the level, any new Cat 8 points count toward your overall score, but don't "roll over" into the next level.
The number of Categories is small (five currently) and unlikely to change often, but by no means absolutely fixed.
The number of points needed to level-up will vary per level, probably by a formula, or perhaps a lookup table.
So the challenge is to track each user's progress toward the next level in each category. I've thought of a few potential approaches:
Possible Solutions
Add a column to the users table for each category and reset them all to zero each time a user levels-up.
Have a separate UserProgress table with a row for each category for each user and the number of points they have. (Basically a Many-to-Many version of #1.)
Add a userLevel column to the UserTasks table and use that to derive their progress with some kind of SUM statement.
Their current level will be a simple int in the User table.
Pros & Cons
(1) seems like by far the most straightforward, but it's also the least flexible. Perhaps I could use a naming convention based on the category ids to help overcome some of that. (With code like "select cats; for each cat, get the value from Users.progress_{cat.id}.") It's also the one where I lose the most data -- I won't know which points counted toward leveling up. I don't have a need in mind for that, so maybe I don't care about that.
(2) seems complicated: every time I add or subtract a user or a category, I have to maintain the other table. I foresee synchronization challenges.
(3) Is somewhere in between -- cleaner than #2, but less intuitive than #1. In order to find out where a user is, I'd have mildly complex SQL like:
SELECT categoryId, SUM(points) from UserTasks WHERE userId={user.id} & countsTowardLevel={user.level} groupBy categoryId
Hmm... that doesn't seem so bad. I think I'm talking myself into #3 here, but would love any input, advice or other ideas.
As a way to prevent the major annoyances of browser segmentation and older versions. This way the code would only need to be done for the latest version of the browser, but users could still have the functionality of the older version and not be forced to do major updates?
I am sure there will be some major flaws in this, and I would like you to tell me what they are!
-Obviously, people may not want this as often auto-updating is frowned upon, however Chrome does it (or at least, they used to);
Without a manual check, Chrome will update itself automatically, Google said. "Google Chrome will automatically checks for updates approximately every five hours. If an update is available, it will be downloaded and applied at the next browser restart," Google said.
-there is still the problem of getting users from the really old ones onto the any new browsers that have this functionality
-To prevent exploits in terms of updates, maybe they could have a 7 day opt-in period before being pushed out to everyone?
I'm using the java swing library to develop a board game called DAO.
The problem is that after the human player makes its move, by clicking on the JButton with the piece image that he wants to play, I call the computer AI routine but inside the mouse event function. By doing this only when the function returns, the computer ends its turn, do the JButtons refresh their Images (setIcon comes in).
I'd like to know how can I force the JButtons to change their image at the moment they are clicked and not only when the mouse event function ends (as I need to handle data inside it).
I've tried all of this
myButtons[i][j].setIcon(xIcon);
myButtons[i][j].revalidate();
myButtons[i][j].repaint();
myButtons[i][j].validate();
None worked.
Thx in advance
http://stackoverflow.com/questions/3028161/project-help-needed-some-basic-concepts-great-confusion-because-of-lack-of-prope
where can i ask questions where my post will not be deleted because of "it difficult to say what is being asked" i mean general waste area covering questions like the one i asked in.... and please gve links to help forums where there are experts like you before closing this question thank you
I need to learn how to develop PHP extensions.
So, I assume I have to refresh my CPP skills (or is it C?).
What IDE should I use (auto-completion, object browsers etc). I plan to develop on Ubuntu 32.
Is there a good book or good website I can learn from?
Hi,
i'm trying to develop Pentago-game in c#.
right now i'm having 2 players mode which working just fine.
the problem is, that i want One player mode (against computer), but unfortunately, all implements of minimax / negamax are for one step calculated.
butin Pentago, every player need to do two things (place marble, and rotate one of the inner-boards)
I didn't figure out how to implement both rotate part & placing the marble, and i would love someone to guide me with this.
if you're not familiar with the game, here's a link to the game.
if anyone want's, i can upload my code somewhere if that's relevant.
thank you very much in advance
How to get live currency rates and quotes of stocks? It can be any country related. So that I can integrate them in my application. I just don't know where to start with. Looking forward for a right direction to start with.
Hello All,
I have a big problem with Google Chrome and its memory. My app is displaying to user several image charts and reloads them every 10s.
In the interval i have code like that
var image = new Image();
var src = 'myurl/image'+new Date().getTime();
image.onload = function() {
document.getElementById('myimage').src = src;
image.onload = image.onabort = image.onerror = null;
}
image.src = src;
So i have no memory leaks in Firefox and IE.
Here the response headers for images
Server Apache-Coyote/1.1
Vary *
Cache-Control no-store (// I try no-cache, must-revalidate and so on here)
Content-Type image/png
Content-Length 11131
Date Mon, 31 May 2010 14:00:28 GMT
Vary * taken from here
In about:cache page there is no my cached images.
If i enable purge-memory-button for chrome (--purge-memory-button parameter) it`s not help.
Images is in PNG24.
So i think that the problem is not in cache.
May be Google Chrome is not releasing memory for old images.
Please help. Any suggestions.
Thanks.
Hello.
I'm developing a Flash game in ActionScript 2, and the issue if that this game has to count the time securely.
It can't count the time from the Date class because the Flash Player takes the time from the local computer, and the user can change the local time so the time reported would be fake.
I haven't considerend to take the time from the server because there's a 3WH (3 way handshake) time and it would not be practical.
What do you sugest me??
Hello,
this questions may be stupid, but i dont really see how to resolve it :
lest say that in my application, i have a user. This user edit his profile, and need to edit his avatar.
Where should i store the avatar file?
first of all i was saving all the files in src\main\webapp\resources , but each time i redeploy that folder empties.
so i dedide to place in an other location : c:\wwwdir\resources, but i can't link local resources from remote pages, so i was not able to display any avatar .
any idea? advise? link?
When a user clicks a button I need to create a .bmp file on the server. After the .bmp file is created I will load it into the html page. Would Ajax be the best way to accomplish this?
Hello everyone,
I notice this site has a wealth of software professionals and I am investigating a career change to Software Engineering:
*Particularly, I would like to know how likely one would be able to work from home or another country over the internet. Is this something that can be done and what does it usually entail? (time?,experience?, specific companies?, etc)
*Currently, I am a teacher but always had a passion for tech. I am interested in a MS - Software Engineering program designed for individuals based from another field. Is this a wise degree to obtain? Would I be just wasting my time and money obtaining this degree? (I'm suspicious about this program and the feasibility of obtaining employment without a healthy CS background)
Thanks for any assistance you can provide!
What are your best practices for making sure newly hired developers quickly get up to speed with the code? And ensuring developers moving on don't set back ongoing releases.
Some ideas to get started:
Documentation
Use well established frameworks
Training / encourage mentoring
Notice period in contract
In my urls.py I have this:
(r'^myapp/$', 'myapp.views.views.index'),
(r'^myapp/login/$', 'myapp.views.views.login_user'),
In my settings.py I have this:
LOGIN_URL = '/myapp/login'
In my views.py I have this:
@login_required((login_url='/myapp/login/')
def index(request):
return render_to_response('index.html')
def login_user(request):
#login stuff
return render(request, 'registration/login.html', {'state':state, 'username': username})
I can go to mysite.com/myapp/login and the login page works. However, when I go to mysite.com/myapp/index I do not get redirected to the login page even though I am logged out. Why is that and how do I fix it?
Hello,
How Do I deploy applications so that they require administrator rights without the end-user doing that by hand?
I use Delphi 2009 to build the application.
To learn from good examples, what are the best open source Google App Engine applications out there?
I don't care if it is Java or Python based.
Please one app per answer. Feel free to add a link to the live app (if there is) and to the project page.
I need to put a map in a webpage and I need that when the users clicks on certain area inside city limits on the map the user is redirected.
Wich is the best way without using Flash?
Define Hover polingons on a image.
SVG on the browser.
Some sort of Javascript, jQuery magical plugin out there?
Google Maps?
And example could be this but It's flash.
Hello All-
I'm having trouble with a URL string in my Web Application. It's using a UNC path similar to \\houtestmachine\common\File1.pdf My problem is when it encounters files that have a # character. I tried doing a string newstring = originalstring.Replace("#", "%23"); but the # is still there in URL (target of a hyperlink) at runtime in the browser. How can I fix this?
I've made a footer wrap outside the content wrap (which everything else is in). I would like to make the footer wrap extend to fill the width of the page and I would like it to be fixed on the bottom. Here's the code:
footerWrap {
background-color:#000;
width: auto;
}
footer {
margin: auto;
text-align:center;
width:965px;
height:150px;
background-color:#000;
border:#000 inset medium;
}
The website is item9andthemadhatters.com please let me know if you need any other code or info. Thanks!!
update:
html {
padding:0;
height:100%;
width: 100%;
}
body{
margin: -1px 0 0 0;
background-color:#FFF;
font-family: calibri;
background-image:url(images/item9HeaderSideFiller.gif);
background-repeat: repeat-x;
padding:0;
height:100%;
width: 100%;
}
wrap {
width: 965px;
margin:auto auto;
min-height:462px;
max-height:4000
px;
footerWrap {
background-color:#000;
position:absolute;
bottom:0;
width:100%
}
footer {
margin: auto;
text-align:center;
width:965px;
height:150px;
background-color:#000;
}
}
I am looking fr someone to make me two website templates for my site for free.
Here is a quick design of what I want:(Took me 2 minutes in Paint)
http:/ /i50.tinypic.com/33p9aut.jpg (You have to push backspace on the first link to join up the http:/ and the other /)and http://i50.tinypic.com/2qmogoo.jpg
Email me at [email protected] or [email protected] for more information