Posts

PHP files for users -

i'm trying understand concept i've been trying learn last couple days; i see many social networks using user's id in url after file (example: "socialnetwork.php?id=123") navigate user. i want make profile.php same thing instead of directing me homepage everytime. question: how can use user's id in database read out unique profile data them in single file? - furthermore, should add register_config.php file allow this? <?php //requiring pass api config require 'password_config.php'; require 'connect.php'; //variables post data //other variables $email = $_post['register_email']; $username = $_post['register_username']; $userlen = strlen($username); $password = $_post['register_password']; $passlen = strlen($password); $submit = $_post['register_submit']; $hash_password = password_hash($password,password_bcrypt); $query = "s...

ubuntu 12.04 - Nginx domain work without be into sites-enabled -

i have strange bug in nginx configuration. if stop nginx, every domains stop working, normal. if remove or comment include /etc/nginx/sites-enabled/*; (in nginx.conf) every domains stop working, normal. if rename sites-enabled folder, nginx wont restart , domain stop working, normal. if remove sites-enabled folder, nginx wont restart , domain stop working, normal. but if remove domaine sites-enabled folder, restart/reload nginx, domain still working. how possible ? there "config cache" somewhere ? ps: reboot server manytime, updated nginx , have exact same configuration in 1 server problem not appear. have deleted default config located in sites-enabled directory? way not critical issue.

c# - ListBox with Rounded Corners (Windows Store App) -

i have listbox inside flyout . there way of making listbox corners rounded? have searched , couldn't find anything. there style/ xaml template recommend? this code: <flyout> <flyout.flyoutpresenterstyle> <style targettype="flyoutpresenter"> <setter property="margin" value="30,30,0,0"/> <setter property="background" value="transparent"/> <setter property="borderbrush" value="transparent"/> <setter property="borderthickness" value="0"/> <setter property="minheight" value="300"/> <setter property="minwidth" value="200"/> </style> </flyout.flyoutpresenterstyle> <listbox x:name="allitemsview" width="200" height="auto" border...

Adding Bootstrap to Jekyll -

i'm new jekyll , pull in of twitter bootstrap functionality. has done and, if so, have advice? have gone jekyll-bootstrap, there no longer support it. have built jekyll site , hoping there's way pull in bootstrap. as jekyll natively supports sass, can use bootstrap-sass . i install bower install bootstrap-sass command. this installs bootstrap , jquery in bower_components folder. configuration in _config.yml add : sass: # loading path site root # default _sass sass_dir: bower_components/bootstrap-sass/assets/stylesheets # style : nested (default), compact, compressed, expanded # :nested, :compact, :compressed, :expanded works # see http://sass-lang.com/documentation/file.sass_reference.html#output_style # on typical twitter bootstrap stats : # nested 138,7kb, compact 129,1kb, expanded 135,9 kb, compressed 122,4 kb style: compressed javascript if want use javascript, in _includes/footer.html add : <script src="{{ s...

mysql - C# - Kerosene ORM - Can't find the default engine and the connection string -

i new c#/.net world , trying developp c# application using kerosene orm link mysql database. it's local database hosted wamp. to initiate connection database via keroseneorm need provide engine name , connection string. what engine name ? in kerosene code it's described : /// <param name="name">a string containing either invariant name of engine, or /// tail part, or name of connection string entry in configuration files, /// or null. in later case, name of default connection string entry used.</param> i don't know "engine" tried add connection string entry in app.config file : <connectionstrings> <clear /> <add name="localdb" providername="mysql.data.mysqlclient" connectionstring="server=localhost;database=bms;uid=root;pwd=root;" /> </connectionstrings> but rise exception "cannot find 'localdb' registered engine." so basically, "e...

javascript - How to use "change event" in bootstrap-wysiwyg? -

i using bootstrap-wysiwyg. i need event occur after text modified , input box blurred. i saw below code, isn't event want // bind event event $('#wysiwyg').wysiwyg('document').keypress(function(e) { // cancel keypress e.preventdefault(); // alert alert('keypress detected!'); }); i want event occur after text modified , input box blurred. event want similar ".change()" in jquery. i hope me.. thank you.. i know question bit old, here's how can in case still need solve issue in future. assuming you're using latest version of bootstrap-wysiwyg can you're wanting using following code: $('#wysiwyg').wysiwyg().on('change', function() { // code goes here }); you can download latest version here .

ocaml - Why are int32s/int64s slower than ints? -

i've read in reference doc of int32 module: performance notice: values of type int32 occupy more memory space values of type int, , arithmetic operations on int32 slower on int. use int32 when application requires exact 32-bit arithmetic. why int32s happen slower ints? because boxed or something? is because boxed or something? yes.