Kruptein 15 Posting Whiz in Training

Is it possible that you are using java 5 on Linux and java 6 or later on windows?
if that's true, you have to upgrade to java 6 or later on linux

Kruptein 15 Posting Whiz in Training

You have inside your computer a battery this one can be charged with the adapter...

Kruptein 15 Posting Whiz in Training

I already heard of it,

but I don't think it is so handy, talking about updates etc.
I prefer to have the most recent version and I don't know ninite will be able to guarantee this.

Kruptein 15 Posting Whiz in Training

Your battery inside your acer may be broken ?

Kruptein 15 Posting Whiz in Training

lol I even can't find a "1" in line 1 xD
try to delete the space between the table-name and the (
(It is possibly not the problem, but you can always try)

Kruptein 15 Posting Whiz in Training

I agree with ElegantElephant w3schools is indeed very good.

Kruptein 15 Posting Whiz in Training

a) Buy a book
b) follow a free tutorial on the web: google is your friend

We (the daniweb community) are always present to help you if you have something you don't understand, but you will not find someone (although not easily) who will teach you everything in return of nothing, we all started with books or tutorials...

Kruptein 15 Posting Whiz in Training

If I do this code in the command line:

f = open(fl, 'r')
txt = ""
for line in f:
    txt+=line
f.close()
print txt

I get all the output for the file fl, but if I do:

def editfl(self, fl):
        f = open(fl, 'r')
        txt = ""
        for line in f:
            txt+=line
        f.close()
        self.notebook_1.SetSelection(2)
        self.dedfrom = "fm"
        self.dedfl = fl
        self.text_ctrl_8.SetValue(txt)

then I only get the first 8-9 lines,
Until now it only occurs with this file (a log file generated by logkeys),
other (longer) files appear right...

What is causing the problems?

P.S.:If I try it with gedit I only get a bunch of weird not ASCII signs.
in bash, `cat` does output the content of the file right :s

Kruptein 15 Posting Whiz in Training

Okay never-mind I found the problem, it had to be: self.stilltext.ShowModal()

Kruptein 15 Posting Whiz in Training

In line 127
self.stilltext = StillText(DEDITOR(self), -1, "")
creates a new instance of class DEDITOR, you want to use the instance created in __main__

I would think that I should use deditor (in lowercase) then, but that throws an error: DEDITOR object is not callable

if I try StillText(None, -1, "") instead it just won't work either =s

Kruptein 15 Posting Whiz in Training

Again I have problems with my classes :s
I want to test if there is still text in the text_ctrl, if so it should give a warning in which you can chose to cancel, save or continue;

but somehow the deditor.st = "continue" is not passed :s

#!/usr/bin/env python
# -*- coding: utf-8 -*-
# generated by wxGlade 0.6.3 on Sun Nov 29 18:42:47 2009

import wx, os, datetime, stat
from ftplib import FTP

# begin wxGlade: extracode
# end wxGlade

class StillText(wx.Dialog):
    def __init__(self, *args, **kwds):
        # begin wxGlade: StillText.__init__
        kwds["style"] = wx.DEFAULT_DIALOG_STYLE
        wx.Dialog.__init__(self, *args, **kwds)
        self.label_1 = wx.StaticText(self, -1, "ATTENTION: THERE IS STILL A FILE OPENED!", style=wx.ALIGN_CENTRE)
        self.button_1 = wx.Button(self, -1, "Save")
        self.button_2 = wx.Button(self, -1, "Continue")
        self.button_3 = wx.Button(self, -1, "Cancel")

        self.__set_properties()
        self.__do_layout()

        self.Bind(wx.EVT_BUTTON, self.save_file, self.button_1)
        self.Bind(wx.EVT_BUTTON, self.continu, self.button_2)
        self.Bind(wx.EVT_BUTTON, self.cancel, self.button_3)
        # end wxGlade

    def __set_properties(self):
        # begin wxGlade: StillText.__set_properties
        self.SetTitle("ATTENTION!")
        # end wxGlade

    def __do_layout(self):
        # begin wxGlade: StillText.__do_layout
        sizer_2 = wx.BoxSizer(wx.VERTICAL)
        sizer_2_copy = wx.BoxSizer(wx.HORIZONTAL)
        sizer_2.Add(self.label_1, 0, wx.EXPAND|wx.ALIGN_CENTER_HORIZONTAL|wx.ALIGN_CENTER_VERTICAL|wx.ADJUST_MINSIZE, 0)
        sizer_2_copy.Add(self.button_1, 0, wx.ALIGN_CENTER_HORIZONTAL|wx.ALIGN_CENTER_VERTICAL|wx.ADJUST_MINSIZE, 0)
        sizer_2_copy.Add(self.button_2, 0, wx.ALIGN_CENTER_HORIZONTAL|wx.ALIGN_CENTER_VERTICAL|wx.ADJUST_MINSIZE, 0)
        sizer_2_copy.Add(self.button_3, 0, wx.ALIGN_CENTER_HORIZONTAL|wx.ALIGN_CENTER_VERTICAL|wx.ADJUST_MINSIZE, 0)
        sizer_2.Add(sizer_2_copy, 0, wx.EXPAND|wx.ALIGN_CENTER_HORIZONTAL|wx.ALIGN_CENTER_VERTICAL, 0)
        self.SetSizer(sizer_2)
        sizer_2.Fit(self)
        self.Layout()
        # end wxGlade

    def save_file(self, event): # wxGlade: StillText.<event_handler>
        deditor.save_file("")
        deditor.st = "save"
        self.Close()

    def continu(self, event): # wxGlade: StillText.<event_handler>
        deditor.st = "continue"
        self.Close()

    def cancel(self, event): # wxGlade: StillText.<event_handler>
        deditor.st = "cancel"
        self.Close()

# end of class StillText


class DEDITOR(wx.Frame):
    def __init__(self, *args, **kwds):
        # begin wxGlade: DEDITOR.__init__
        kwds["style"] = wx.DEFAULT_FRAME_STYLE
        wx.Frame.__init__(self, *args, **kwds)
        
        # Menu Bar
        self.deditor_menubar = wx.MenuBar()
        wxglade_tmp_menu = wx.Menu() …
Kruptein 15 Posting Whiz in Training

Also, its good practice to not have functions that are using names that are already taken. Such as print, int, str, list bool and so on. So it's probably best if you change your list() function to another name. :)

I know, but because this was just a quickly built example, I didn't really look at the names; but you're right =)


btw thanks vegaseat

Kruptein 15 Posting Whiz in Training

Okay I made a frame with a listbox and a button to open the MyFrame2.
the MyFrame2 contains a textbox and a button to output its content in the listbox

but the listbox is not update =(

#!/usr/bin/env python
# -*- coding: utf-8 -*-
# generated by wxGlade 0.6.3 on Sun Feb 14 17:36:36 2010

import wx

# begin wxGlade: extracode
# end wxGlade



class MyFrame(wx.Frame):
    def __init__(self, *args, **kwds):
        # begin wxGlade: MyFrame.__init__
        kwds["style"] = wx.DEFAULT_FRAME_STYLE
        wx.Frame.__init__(self, *args, **kwds)
        self.list_box_1 = wx.ListBox(self, -1, choices=[])
        self.open_panel = wx.Button(self, -1, "Open panel")

        self.__set_properties()
        self.__do_layout()

        self.Bind(wx.EVT_BUTTON, self.openpanel, self.open_panel)
        # end wxGlade

    def __set_properties(self):
        # begin wxGlade: MyFrame.__set_properties
        self.SetTitle("frame_1")
        # end wxGlade

    def __do_layout(self):
        # begin wxGlade: MyFrame.__do_layout
        sizer_1 = wx.BoxSizer(wx.VERTICAL)
        sizer_2 = wx.BoxSizer(wx.HORIZONTAL)
        sizer_2.Add(self.list_box_1, 0, wx.ADJUST_MINSIZE, 0)
        sizer_2.Add(self.open_panel, 0, wx.ADJUST_MINSIZE, 0)
        sizer_1.Add(sizer_2, 1, wx.EXPAND, 0)
        self.SetSizer(sizer_1)
        sizer_1.Fit(self)
        self.Layout()
        # end wxGlade

    def openpanel(self, event): # wxGlade: MyFrame.<event_handler>
        self.panel = MyFrame2(MyFrame(self), -1, "")
        self.panel.Show()

# end of class MyFrame


class MyFrame2(wx.Frame):
    def __init__(self, *args, **kwds):
        # begin wxGlade: MyPanel.__init__
        kwds["style"] = wx.DEFAULT_FRAME_STYLE
        wx.Frame.__init__(self, *args, **kwds)
        self.text_ctrl_1 = wx.TextCtrl(self, -1, "")
        self.button_1 = wx.Button(self, -1, "button_1")

        self.__set_properties()
        self.__do_layout()

        self.Bind(wx.EVT_BUTTON, self.list, self.button_1)
        # end wxGlade

    def __set_properties(self):
        # begin wxGlade: MyPanel.__set_properties
        pass
        # end wxGlade

    def __do_layout(self):
        # begin wxGlade: MyPanel.__do_layout
        sizer_3 = wx.BoxSizer(wx.VERTICAL)
        sizer_3.Add(self.text_ctrl_1, 0, wx.ADJUST_MINSIZE, 0)
        sizer_3.Add(self.button_1, 0, wx.ADJUST_MINSIZE, 0)
        self.SetSizer(sizer_3)
        sizer_3.Fit(self)
        # end wxGlade

    def list(self, event): # wxGlade: MyPanel.<event_handler>
        myframe = MyFrame(None, -1 , "")
        myframe.list_box_1.Append(self.text_ctrl_1.GetValue())

# end of class MyPanel


if __name__ == "__main__":
    app = wx.PySimpleApp(0) …
Kruptein 15 Posting Whiz in Training

Thanks a lot

Kruptein 15 Posting Whiz in Training

btw it does not trow an error :s and if I print the value of myframe.filedir after that it is changed, it contains the right value. ...

Kruptein 15 Posting Whiz in Training

try this: find ./ -type f -exec test $( `ftype {}` ) = 'image' \;

Kruptein 15 Posting Whiz in Training

Well the class MyFrame is over 1000 lines of code but I will give you the initialization from wx itself:

class MyFrame(wx.Frame):
    def __init__(self, *args, **kwds):
        # begin wxGlade: MyFrame.__init__
        kwds["style"] = wx.DEFAULT_FRAME_STYLE
        wx.Frame.__init__(self, *args, **kwds)
        self.notebook_1 = wx.Notebook(self, -1, style=0)
        self.notebook_1_pane_4 = wx.Panel(self.notebook_1, -1)
        self.notebook_1_pane_3 = wx.Panel(self.notebook_1, 3)
        self.notebook_1_pane_2 = wx.Panel(self.notebook_1, 2)
        self.notebook_1_pane_1 = wx.Panel(self.notebook_1, 1)
        self.notebook_3 = wx.Notebook(self.notebook_1_pane_1, -1, style=wx.NB_RIGHT)
        self.notebook_3_pane_2 = wx.Panel(self.notebook_3, -1)
        self.notebook_3_pane_1 = wx.Panel(self.notebook_3, -1)
        
        # Menu Bar
        self.menubar = wx.MenuBar()
        wxglade_tmp_menu = wx.Menu()
        wxglade_tmp_menu.Append(5, "Options", "", wx.ITEM_NORMAL)
        wxglade_tmp_menu.Append(12, "Extlib Manager", "", wx.ITEM_NORMAL)
        wxglade_tmp_menu.Append(13, "Update Extlib", "", wx.ITEM_NORMAL)
        wxglade_tmp_menu.Append(11, "Open FIle", "", wx.ITEM_NORMAL)
        wxglade_tmp_menu.AppendSeparator()
        wxglade_tmp_menu.Append(2, "Quit", "", wx.ITEM_NORMAL)
        self.menubar.Append(wxglade_tmp_menu, "DCM")
        wxglade_tmp_menu = wx.Menu()
        wxglade_tmp_menu.Append(1, "Change Dir", "", wx.ITEM_NORMAL)
        self.menubar.Append(wxglade_tmp_menu, "File Manager")
        wxglade_tmp_menu = wx.Menu()
        wxglade_tmp_menu.Append(3, "Start", "", wx.ITEM_NORMAL)
        wxglade_tmp_menu.Append(4, "Stop", "", wx.ITEM_NORMAL)
        self.menubar.Append(wxglade_tmp_menu, "MySql")
        wxglade_tmp_menu = wx.Menu()
        wxglade_tmp_menu.Append(6, "start", "", wx.ITEM_NORMAL)
        wxglade_tmp_menu.Append(7, "stop", "", wx.ITEM_NORMAL)
        self.menubar.Append(wxglade_tmp_menu, "FTP")
        wxglade_tmp_menu = wx.Menu()
        wxglade_tmp_menu.Append(8, "Save", "", wx.ITEM_NORMAL)
        wxglade_tmp_menu.Append(9, "Upload (FTP)", "", wx.ITEM_NORMAL)
        wxglade_tmp_menu.Append(10, "2nd Deditor", "", wx.ITEM_NORMAL)
        self.menubar.Append(wxglade_tmp_menu, "Deditor")
        self.SetMenuBar(self.menubar)
        # Menu Bar end
        self.statusbar = self.CreateStatusBar(0, 0)
        self.list_box_1 = wx.ListBox(self.notebook_1_pane_1, -1, choices=[])
        self.label_1 = wx.StaticText(self.notebook_3_pane_1, -1, "Name:")
        self.label_2 = wx.StaticText(self.notebook_3_pane_1, -1, "")
        self.label_15 = wx.StaticText(self.notebook_3_pane_1, -1, "Size:")
        self.label_16 = wx.StaticText(self.notebook_3_pane_1, -1, "")
        self.button_1 = wx.Button(self.notebook_3_pane_1, -1, "DOPEN")
        self.button_2 = wx.Button(self.notebook_3_pane_1, -1, "Edit")
        self.text_ctrl_1 = wx.TextCtrl(self.notebook_3_pane_2, -1, "")
        self.button_3 = wx.Button(self.notebook_3_pane_2, -1, "Rename")
        self.text_ctrl_12 = wx.TextCtrl(self.notebook_3_pane_2, -1, "")
        self.button_4 = wx.Button(self.notebook_3_pane_2, -1, "Chmod")
        self.radio_box_1 = wx.RadioBox(self.notebook_3_pane_2, -1, "chmod input", choices=["octal", "symbolic"], majorDimension=0, style=wx.RA_SPECIFY_ROWS)
        self.label_17 = wx.StaticText(self.notebook_3_pane_2, -1, "example:\nOctal        (0)755\nSymbolic  rwxr-xr-x")
        self.list_box_3 = wx.ListBox(self.notebook_1_pane_2, -1, choices=[])
        self.text_ctrl_2 = …
Kruptein 15 Posting Whiz in Training

You got to let us know what class MyFrame looks like and how you instantiate class ChangeDirPanel so that widget self.text_ctrl_16 can be passed through.

the problem is probably with the last, because I'm not sure it is completely right...I initiate it like this (in MyFrame):

def change_dir(self, event): # wxGlade: MyFrame.<event_handler>
        self.chgedirframe = ChangeDirPanel(MyFrame(self), -1, "")
        self.chgedirframe.Show()
Kruptein 15 Posting Whiz in Training

Okay also here I cleaned the indentations but no luck, it still does not change the listbox...

def changedir(self, event): # wxGlade: ChangeDirPanel.<event_handler>
        myframe = MyFrame(None, -1, "")
        myframe.SetStatusText("Hello")
        myframe.filedir = self.text_ctrl_16.GetValue()
        myframe.file_show_dir()
Kruptein 15 Posting Whiz in Training

Alright I cleaned the indents and it still gives the same problem ...

def extupdate(self, event): # wxGlade: MyFrame.<event_handler>
        p=os.popen(self.dcmdir + "/dcmd -u")
        version=p.readlines()
        p.close()
        if p == "uptodate":
            pass
        else:
            os.system("curl http://d-cm.googlecode.com/files/extlib.ded -o "+self.dcmdir+"/DOPEN/dwnext.ded")
            append=""
            content=""
            x="n"
            g=open(self.dcmdir+"/DOPEN/extlib.ded",'r')
            f=open(self.dcmdir+"/DOPEN/dwnext.ded",'r')
            for line in f.readlines():
                for ln in g.readlines():
                    if line.strip().split("|")[0] == ln.strip().split("|")[0]:
                        x="y"
                    content=content+ln
                    print line
                if x!="y":
                    print line
                    append=append+line
                x="n"
            f.close()
            g.close()
            #f=open(self.dcmdir+"/DOPEN/extlib.ded",'w')
            print "append "+append
            print "c "+content
            print "ac "+append+content
            #f.write()
            #f.close()
Kruptein 15 Posting Whiz in Training

Your favorite editor DOES have a configuration option to write 4 spaces instead of a tab !

Okay I didn't know that gedit had such thing.
I will redo all my indentations and report if their are new problems

Kruptein 15 Posting Whiz in Training

Why can't I use tabs ? I hate it when I every time have to hit 4 times the tab.
Btw every program I made till now works with those tabs.

Kruptein 15 Posting Whiz in Training

I really don't see what is wrong =(.
First I download via curl a file, then I want to compare it to a local file
there are 15 lines in dwnext.ded
and there are 14 lines in extlib.ded

I want to store in append those lines that have a string before the "|" that is not in a line in the local file
In content i just want to store all the local lines again

like you can see I added two times: print line when I run the script I get 14 times the first line of dwnext.ded and then the other 14 lines all once.
Also append contains all lines from dwnext instead of the lines that were not found on the local :(

(I hope my summary is clear enough :p)
P.S.: I do not get errors

os.system("curl http://d-cm.googlecode.com/files/extlib.ded -o "+self.dcmdir+"/DOPEN/dwnext.ded")
		append=""
		content=""
		x="n"
		g=open(self.dcmdir+"/DOPEN/extlib.ded",'r')
		f=open(self.dcmdir+"/DOPEN/dwnext.ded",'r')
		for line in f.readlines():
			for ln in g.readlines():
				if line.strip().split("|")[0] == ln.strip().split("|")[0]:
					x="y"
				content=content+ln
				print line
			if x!="y":
				print line
				append=append+line
			x="n"
		f.close()
		g.close()
Kruptein 15 Posting Whiz in Training

You have a lot of them,
depending on which subject:
-last.fm
-netlog.nl
-...

a list

Kruptein 15 Posting Whiz in Training

i hope somebody gets this. lol. i am looking to create a game much like:
http://www.ogame.org/ and http://www.zorgempire.net/

what all do i need 2 know in order 2 do this?
thanx

You have to know at least: html and css
and a server side language. I advise PHP, because it is very easy to start with and is used a lot. you can though choose for something else like platinum8 said before.

Be aware that you will not make something like ogame in 1 month, or even a half year if you don't know anything about it.

Kruptein 15 Posting Whiz in Training

Well I also only work on it in my free time. but some info:
-it's a program for web-programmers, it bundles a mysql-manager,ftp-manager,file-manager,text-editor all in one so you don't have to open a lot of programs
-it's written in python, module wxPython
-It is written with the focus on linux, so If you use windows, it probably won't work like it should.
-it can be found here: http://code.google.com/p/d-cm
(svn (subversion) is always the most recent version, but you can also download a tar.gz)

It would be glad if persons could test the file-manager and the mysql manager. The ftp-manager can be used, but I'm afraid their are still a lot of bugs. The text-editor can only open and save files not yet create new ones xD

if you need more info please contact me on mail (darragh.ssa@gmail.com) or @ googlecode.com thanks

It's opensource btw

Kruptein 15 Posting Whiz in Training

Are their people willing to help testing/contributing to a python project?

(if this is not a 'legal' subject, feel free to delete it; I wasn't sure)

Kruptein 15 Posting Whiz in Training

Some goofy indentations in there.

Is that the reason for this?
All my other functions etc.. work great

Kruptein 15 Posting Whiz in Training

I have a Frame called ChangeDirPanel and an other one called MyFrame, the last one is the top-lvl window and has a function called file_show_dir which updates a listbox in that same window.

(both frames have their own class, is it better to have the same class?)

I want to run the function from an other frame (the changedirpanel)
but somehow the listbox isn't updated =(

I really don't see why

ChangeDirPanel class

class ChangeDirPanel(wx.Frame):
    #left init away

    def changedir(self, event): # wxGlade: ChangeDirPanel.<event_handler>
	myframe = MyFrame(None, -1, "")
	myrame.SetStatusText("Hello")
                myframe.filedir = self.text_ctrl_16.GetValue()
	myframe.file_show_dir()

    def cancel(self, event): # wxGlade: ChangeDirPanel.<event_handler>
        self.Close()

# end of class ChangeDirPanel
Kruptein 15 Posting Whiz in Training

Okay this is the last change to the code: (without errors or endless loops)

#/bin/bash
file="/home/darragh/Bureaublad/test.txt"
data=`cat $file`
data=${data#*<}
n=0
x=0
while [ $x = 0 ]
do
 if [[ "$data" =~ \ |\' ]]
 then
  x=0
 else
  if [ $n = 1 ]
  then
   x=1
  fi
 fi
 if [ $n = 0 ]
 then
  serial=${data%%>*}
  n=1
 else
  echo `echo ${data%%>*}` >> $serial.txt
  n=0
 fi
 data=${data#*<}
done

I know you can make it shorter with all those if's but I have to go now,
I hope i helped

Kruptein 15 Posting Whiz in Training

I just found out, that there are some minor issues which will not affect your data:
-loop keeps going even if all files are made (I'm fixing that one)
-in terminal it will drop an error that it expects a unary = or something but this will not harm the code

Kruptein 15 Posting Whiz in Training
#/bin/bash
file="/home/darragh/Bureaublad/test.txt"
data=`cat $file`
data=${data#*<}
n=0
until [ `echo ${data#*>}` = "." ]
do
 if [ $n = 0 ]
 then
  serial=${data%%>*}
  n=1
 else
  echo `echo ${data%%>*}` >> $serial.txt
  n=0
 fi
 data=${data#*<}
done

this one works without any error

the only requirment is that the first "<" is followed by a serial number

(if you want to know how this works, please pm me, or answer on this topic)

Kruptein 15 Posting Whiz in Training

DON'T USE YET, I found a problem, when this line is away it should be solved =)

file="/path/to/file"
data=""
data=`cat $file`
serial=""
for i in "$file"; do
 if [ `expr index "$i" .` = 1 ]
 then
   serial=`echo $i | tr -dc '[0-9]'`
 else
  echo `echo $i | tr -dc '[0-9]'` >> $serial.txt
 fi
done

I didn't test this so be aware =D
the for loop goes trough every line of the file specified in line 1,
the if loop checks weither the line starts with a . (dot),
if it starts with a dot, it get's the serial number
otherwise it will append the article information to a file with the serial number as a name.


I hope it works =D

Kruptein 15 Posting Whiz in Training

Ah now I got it =D, yes with javascript it should be possible

Kruptein 15 Posting Whiz in Training

First: this is not php but html and css
second: you can just use div's in div's

<div style='...'>
    <div style='...'>
    </div>
    <div name='a'>
    </div>
</div>
Kruptein 15 Posting Whiz in Training

Can you please give the exact error message please?
and are you sure the dbConfig.php is loaded correctly?

Kruptein 15 Posting Whiz in Training

you should be able to do python in command prompt or terminal!
if not python is not installed well

Kruptein 15 Posting Whiz in Training

Okay I think I've a workaround, but to do that I still need your help:

I have in every view a same line, this is not what the DRY-principle says
so I want to write that line once, and the other views should find that line automatic

do you know how?

Kruptein 15 Posting Whiz in Training

I have a base template which is called every time a template is loaded with the {% extend 'base.html' %} tag
In that base file I have a navigation bar with a link to your inbox

I want to show after the link a number with how many unread messages you got, todo that I need to call a python function/view
Is this possible or should I go the javascript/jquery/ajax/... way?

btw: I think there should come a Django tab under web-development

Kruptein 15 Posting Whiz in Training

you should pass them trough a function which defines weither a new product should be added or updated

Kruptein 15 Posting Whiz in Training

the code on my localhost and on the server are completely the same (django), but it is not shown correctly; I include two screenshots

What could be the cause of the difference?

(the left one is the online server; the right one is the localhost)

Kruptein 15 Posting Whiz in Training

You're welcome :)

Kruptein 15 Posting Whiz in Training

maybe this helps:
this is my virtualhost and as you can see I have all files from a certain dir (/usr/local/www/django/ninv) without copy paste them every time I make a change to that directory =)

<VirtualHost *:81>
    Alias /med /usr/local/www/django/ninv/med/
    Alias /admin-media /usr/local/www/django/ninv/admin/media/
    ServerName localhost
    ServerAdmin d@g.com

    DocumentRoot /usr/local/www/django/ninv/

    <Directory /usr/local/www/django/ninv/>
	Options Indexes FollowSymLinks MultiViews
	AllowOverride None
	Order allow,deny
	allow from all
    </Directory>

    WSGIScriptAlias / /usr/local/wsgi/scripts/django.wsgi

    <Directory /usr/local/wsgi/scripts>
    Order allow,deny
    Allow from all
    </Directory>

</VirtualHost>

hope this helps

you should only look at the documentroot and directory tags

Kruptein 15 Posting Whiz in Training

I'm on linux/ubuntu so I have installed:
mysql and apache 2
then you need the wsgi mod

this is my virtualhost configuration in apache (I used port 81 caus I also have a php server running on port 82; but you can configure it like you want to.)

<VirtualHost *:81>
    Alias /med /usr/local/www/django/ninv/med/
    Alias /admin-media /usr/local/www/django/ninv/admin/media/
    ServerName localhost
    ServerAdmin kruptein@kruptein.com

    DocumentRoot /usr/local/www/django/ninv/

    <Directory /usr/local/www/django/ninv/>
	Options Indexes FollowSymLinks MultiViews
	AllowOverride None
	Order allow,deny
	allow from all
    </Directory>

    WSGIScriptAlias / /usr/local/wsgi/scripts/django.wsgi

    <Directory /usr/local/wsgi/scripts>
    Order allow,deny
    Allow from all
    </Directory>

</VirtualHost>

you also need a wsgi conf file:

import os
import sys
sys.path.append('/usr/local/www/django/')
sys.path.append('/usr/local/www/django/ninv/')
os.environ['PYTHON_EGG_CACHE'] = '/usr/local/www/django/ninv/eggs'

os.environ['DJANGO_SETTINGS_MODULE'] = 'ninv.settings'

import django.core.handlers.wsgi
application = django.core.handlers.wsgi.WSGIHandler()

the wsgimod website on google code

Kruptein 15 Posting Whiz in Training

Okay, I don't want to start a new treath,

most famous games probably use c++, but how are they written?
pure from source, with a 3d engine, ... ?

Kruptein 15 Posting Whiz in Training

Well I have a localhost which runs django all for testing the site before it is updated to a new release on the web,

but I have a webhost with already django installed. I don't use lamp anymore.

Kruptein 15 Posting Whiz in Training

Here then here then here

I supposed he already knew html and python itself, but ofcourse he/she should look at that first.. my bad

Kruptein 15 Posting Whiz in Training

To begin with you have to know that python itself is not a web programming language. BUT with help of some frameworks or other things you are able to use python as a web pr. language
I use Django which is a well-supported web framework which uses only python.

Kruptein 15 Posting Whiz in Training

First: Yes I'm comparing apples to oranges but in this case it is kind of possible to compare them

Context: I'm a php-developer for 3-4 years I think and I really like php,
I also use python for 2 years.
I recently came in contact with django (python framework) and I'm now converting my php site into a django one.

Question: I really can't choose weither I should go on with django or just keep going with php. I can't do both of them caus I'm still a student and this would take a lot of my time. What do you guys think about it? own experience? ...

Kruptein 15 Posting Whiz in Training

Well I'm totally django now :) the isntallation was easy (ruby crashed every time =f) and I found a good page with a list of webhosts: djangofriendlywebhost