• Howdy! Welcome to our community of more than 130.000 members devoted to web hosting. This is a great place to get special offers from web hosts and post your own requests or ads. To start posting sign up here. Cheers! /Peo, FreeWebSpace.net
managed wordpress hosting

Post your ctrl+v

def start(self):
if "audacious" not in commands.getoutput("ps -C audacious"):
print "audacious not playing"
exit()

while True:
current_song=commands.getoutput("audtool --current-song")
if "playing" in commands.getoutput("audtool playback-status"):
if self.db.has_key(current_song):
self.parse(self.db[current_song])
nthread(self.play,())
else:
nthread(self.txtCtrl.SetValue,("No Karaoke File For This Song",))

try:
time.sleep(int(commands.getoutput("audtool --current-song-length-seconds"))-
int(commands.getoutput("audtool --current-song-output-length-seconds"))+3)
except: pass
else:
os.system("audacious -p")

Python code.
 
Code:
diff --git a/WebKitTools/GtkLauncher/main.c b/WebKitTools/GtkLauncher/main.c
index 8ed2690..c503f52 100644
--- a/WebKitTools/GtkLauncher/main.c
+++ b/WebKitTools/GtkLauncher/main.c
@@ -34,6 +34,7 @@ static WebKitWebView* web_view;
 static gchar* main_title;
 static gint load_progress;
 static guint status_context_id;
+static GtkWidget* inspector_window;
 
 static void
 activate_uri_entry_cb (GtkWidget* entry, gpointer data)
@@ -89,6 +90,81 @@ load_commit_cb (WebKitWebView* page, WebKitWebFrame* frame, gpointer data)
 }
 
 static void
+hide_window_cb(GtkWidget *widget, gpointer data)
+{
+    gtk_widget_hide(widget);
+}
+
+static WebKitWebView*
+create_inspector_cb (WebKitWebInspector* web_inspector, WebKitWebView* page, gpointer data)
+{
+    GtkWidget* scrolled_window;
+    GtkWidget* new_web_view;
+
+    inspector_window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
+    g_signal_connect(G_OBJECT(inspector_window), "delete-event",
+                     G_CALLBACK(hide_window_cb), NULL);
+
+    gtk_window_set_title(GTK_WINDOW(inspector_window), "Inspector");
+    gtk_window_set_default_size(GTK_WINDOW(inspector_window), 400, 300);
+    gtk_widget_show(inspector_window);
+
+    scrolled_window = gtk_scrolled_window_new(NULL, NULL);
+    gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(scrolled_window),
+                                   GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
+    gtk_container_add(GTK_CONTAINER(inspector_window), scrolled_window);
+    gtk_widget_show(scrolled_window);
+
+    new_web_view = webkit_web_view_new();
+    gtk_container_add(GTK_CONTAINER(scrolled_window), new_web_view);
+
+    return WEBKIT_WEB_VIEW(new_web_view);
+}
+
+static gboolean
+inspector_show_window_cb (WebKitWebInspector* inspector)
+{
+    gtk_widget_show(inspector_window);
+    g_message("show_window: %p", inspector);
+    return TRUE;
+}
+
+static gboolean
+inspector_close_window_cb (WebKitWebInspector* inspector)
+{
+    g_message("close_window");
+    return TRUE;
+}
+
+static gboolean
+inspector_attach_window_cb (WebKitWebInspector* inspector)
+{
+    g_message("attach_window");
+    return FALSE;
+}
+
+static gboolean
+inspector_dettach_window_cb (WebKitWebInspector* inspector)
+{
+    g_message("dettach_window");
+    return FALSE;
+}
+
+static gboolean
+inspector_uri_changed_cb (WebKitWebInspector* inspector)
+{
+    g_message("uri_changed: %s", webkit_web_inspector_get_inspected_uri(inspector));
+    return FALSE;
+}
+
+static gboolean
+inspector_inspector_destroyed_cb (WebKitWebInspector* inspector)
+{
+    g_message("destroy");
+    return FALSE;
+}
+
+static void
 destroy_cb (GtkWidget* widget, gpointer data)
 {
     gtk_main_quit ();
@@ -109,17 +185,33 @@ go_forward_cb (GtkWidget* widget, gpointer data)
 static GtkWidget*
 create_browser ()
 {
+    WebKitWebSettings *settings = webkit_web_settings_new();
+    WebKitWebInspector *inspector;
+
     GtkWidget* scrolled_window = gtk_scrolled_window_new (NULL, NULL);
     gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolled_window), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
 
     web_view = WEBKIT_WEB_VIEW (webkit_web_view_new ());
     gtk_container_add (GTK_CONTAINER (scrolled_window), GTK_WIDGET (web_view));
 
+    g_object_set(G_OBJECT(settings), "enable-developer-extras", TRUE, NULL);
+    webkit_web_view_set_settings(WEBKIT_WEB_VIEW(web_view), settings);
+
     g_signal_connect (G_OBJECT (web_view), "title-changed", G_CALLBACK (title_change_cb), web_view);
     g_signal_connect (G_OBJECT (web_view), "load-progress-changed", G_CALLBACK (progress_change_cb), web_view);
     g_signal_connect (G_OBJECT (web_view), "load-committed", G_CALLBACK (load_commit_cb), web_view);
     g_signal_connect (G_OBJECT (web_view), "hovering-over-link", G_CALLBACK (link_hover_cb), web_view);
 
+    inspector = webkit_web_view_get_inspector(web_view);
+    g_signal_connect (G_OBJECT (inspector), "inspect-web-view", G_CALLBACK (create_inspector_cb), NULL);
+    g_signal_connect (G_OBJECT (inspector), "show-window", G_CALLBACK (inspector_show_window_cb), NULL);
+    g_signal_connect (G_OBJECT (inspector), "close-window", G_CALLBACK (inspector_close_window_cb), NULL);
+    g_signal_connect (G_OBJECT (inspector), "attach-window", G_CALLBACK (inspector_attach_window_cb), NULL);
+    g_signal_connect (G_OBJECT (inspector), "dettach-window", G_CALLBACK (inspector_dettach_window_cb), NULL);
+    g_signal_connect (G_OBJECT (inspector), "destroy", G_CALLBACK (inspector_inspector_destroyed_cb), NULL);
+
+    g_signal_connect (G_OBJECT (inspector), "notify::inspected-uri", G_CALLBACK (inspector_uri_changed_cb), NULL);
+
     return scrolled_window;
 }
^
Web Inspector / WebKit stuff.
 
Last edited:
.<form action="https://www.paypal.com/cgi-bin/webscr" method="post"><input type="hidden" name="cmd" value="_s-xclick"><input type="hidden" name="hosted_button_id" value="5740660"><input type="image" src="https://www.paypal.com/en_AU/i/btn/btn_donateCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online."><img alt="" border="0" src="https://www.paypal.com/en_AU/i/scr/pixel.gif" width="1" height="1"></form>

Hehe it happens to be paypal donations..
 
"Instead of focusing on trends, Sony is going to use its strengths to help make the company financially successful. This will be accomplished through strong products and smart marketing."

Real Life Prediction from a tarot card reader on destructoid.
 
$imgupdb = new wpdb(get_option('imgup_dbuser'),get_option('imgup_dbpwd'), get_option('imgup_dbname'), get_option('imgup_dbhost'));

$insertImg = $imgupdb->get_var("INSERT INTO wp_imguploader (src, user) VALUES ('$_POST[imagesrc]','$_POST[upld_user]')");
 
<?php

include('includes/global.php');

//Build array for Title, Menu, Page Header and Content
$temp_data = array(
'main' => array('file' => $theme),
'cssincludes' => array('content' => $cssIncludes),
'jsincludes' => array('content' => $jsIncludes),
'title' => array('content' => $title),
'metadesc' => array('content' => $metaDesc),
'metakeys' => array('content' => $metaKeys),
'currpage' => array('content' => $currPage),
'actionbox' => array('content' => $actionBox),
'globalnav' => array('content' => $globalNav),
'contactform' => array('content' => $contactForm),
'topcontent' => array('content' => $topContent),
'pagecontent' => array('content' => $pageContent),
'btmcontent' => array('content' => $btmContent),
'footernav' => array('content' => $footerNav),
'copyright' => array('content' => $copyright),
'googleanalytics' => array('content' => $googleAnalytics),
'googletracking' => array('content' => $googleTracking));

$engine = new quick_template($temp_data);
echo $engine -> parse_template();

?>
 
Back
Top