test-ecoff-instagram

By | Code | No Comments
[gc_social_wall]W3sidHlwZSI6Imluc3RhZ3JhbSIsInZhbHVlcyI6W3sibmFtZSI6Im1heF9zeW1ib2xzX3Blcl9wb3N0IiwidmFsdWUiOiIyMDAifSx7Im5hbWUiOiJwb3N0c19wZXJfbG9hZCIsInZhbHVlIjoiNSJ9LHsibmFtZSI6InNlYXJjaF90eXBlIiwidmFsdWUiOiIzIn0seyJuYW1lIjoicXVlcnkiLCJ2YWx1ZSI6IiJ9LHsibmFtZSI6ImNsaWVudF9pZCIsInZhbHVlIjoiZGM1ZjI2MmFlZTZjNGM0MTg3M2M4NTQ5MDFiMGJkYTAifSx7Im5hbWUiOiJpY29uIiwidmFsdWUiOiJmYS1pbnN0YWdyYW0ifSx7Im5hbWUiOiJzaG93X2F1dGhvcl9wYW5lbCIsInZhbHVlIjoib24ifSx7Im5hbWUiOiJzaG93X2NvdW50ZXJzIiwidmFsdWUiOiJvbiJ9LHsibmFtZSI6ImF1dG9fbG9hZCIsInZhbHVlIjoib24ifSx7Im5hbWUiOiJzaG93X2J1dHRvbiIsInZhbHVlIjoib24ifV19XQ==[/gc_social_wall]

Terrenos Condesa de Peñamiller

By | Feature | No Comments

[imagemap id=”12491″]

[sf_iconbox image=”ss-cursor” character=”” color=”accent” type=”boxed-one” title=”INFO.” animation=”flip-y” animation_delay=”200″ link=”” target=”_self”]
Pasa el mouse sobre los terrenos para ver su descripción.
[/sf_iconbox]

I am text block. Click edit button to change this text. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut elit tellus, luctus nec ullamcorper mattis, pulvinar dapibus leo.

I am text block. Click edit button to change this text. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut elit tellus, luctus nec ullamcorper mattis, pulvinar dapibus leo.

[vc_btn title="Read more" style="flat" color="blue"]
IMG_20150925_141032

INDAABIN GUI beta

By | Design, Software | No Comments
[spb_column width=”1/2″ el_position=”first”] [spb_single_image image=”12459″ image_size=”full” frame=”noframe” intro_animation=”fade-in” full_width=”no” lightbox=”yes” link_target=”_self” width=”1/1″ el_position=”first last”] [spb_text_block title=”Team Ideas mockup” icon=”fa fa-cloud” pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

Some of our team ideas about the way the system should flow.

SSO implemented, more than 5 programming languages working together, but the spark of this project is the new UX provided by Razor & AngularJS. Please check the file at bottom for more insight.

[/spb_text_block] [spb_text_block pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

[sf_button colour=”lightgrey” type=”sf-icon-reveal” size=”standard” link=”http://web.swfideas.com/wp-content/uploads/2015/09/sau-interfase-copy.pdf” target=”_blank” icon=”ss-pdf” dropshadow=”no” extraclass=””]View file[/sf_button] [/spb_text_block] [/spb_column] [spb_column width=”1/2″ el_position=”last”] [spb_single_image image=”12453″ image_size=”full” frame=”noframe” intro_animation=”fade-in” full_width=”no” lightbox=”yes” link_target=”_self” width=”1/1″ el_position=”first last”] [spb_single_image image=”12457″ image_size=”full” frame=”noframe” intro_animation=”fade-in” full_width=”no” lightbox=”yes” link_target=”_self” width=”1/1″ el_position=”first last”] [/spb_column]

Downloading multiple files using PowerShell ISE

By | Code | No Comments
[spb_column width=”1/1″ el_position=”first last”] [spb_text_block title=”The Problem” icon=”fa fa-warning” pb_margin_bottom=”no” pb_border_bottom=”no” width=”3/4″ el_position=”first”]

More than once we have to bulk download specific files from our host (simple http requests), at this point nothing out of reach if you just navigate & download the target file using your browser, right? Well, but if you need to download, let’s say 100 files maybe that solution will become unpractical.

[/spb_text_block] [spb_single_image image=”12432″ image_size=”full” frame=”noframe” intro_animation=”fade-in” full_width=”no” lightbox=”yes” link_target=”_self” width=”1/4″ el_position=”last”] [spb_text_block title=”The Solution” icon=”fa fa-lightbulb-o” pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

Using Windows PowerShell Integrated Scripting Environment (ISE) looks like a little brutal but is highly efficient and easy to mold to this kind of problem. So for start you should have this already installed -dho-, if not, mmm… maybe in another tutorial we’ll get to that, for now please go ask Google.

For demo purposes, let’s suppose this is our list of files to download:

Now our script should look like the next:

Check always if your target folder exist before running the script.

Now you’re ready to download your files, just press F5 (Run) and you should see the files at your target folder.

NrKo1aT[1]

 

[/spb_text_block] [/spb_column]
indabin copy_006

INDAABIN mockup

By | Design, Software | No Comments
[sf_gallery title=”Presentation” gallery_id=”12412″ slider_transition=”slide” show_thumbs=”yes” autoplay=”yes” show_captions=”yes” enable_lightbox=”yes” width=”3/4″ el_position=”first”] [spb_column width=”1/4″ el_position=”last”] [spb_text_block title=”Application mockup” icon=”fa fa-lightbulb-o” pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

March/2015
KRKN Solutions & GADAI de México
Some of our ideas for the application flow.

[/spb_text_block] [/spb_column]
9DOKOVx[1]

OpenLayers 3 + Bootstrap 3 – First steps

By | Code, Maps, Software | No Comments
[spb_row parallax_video_height=”video-height” parallax_video_overlay=”none” parallax_image_height=”content-height” parallax_image_movement=”fixed” parallax_image_speed=”0.5″ row_overlay_opacity=”0″ width=”1/1″ el_position=”first last”] [spb_text_block pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

OpenLayers_Icon[1]Step 1 – Setting the ground

Even if you actually know how to make your Bootstrap test-ground, I highly recommend you give this a try, if not, just go to step 2 (Windows users), if you’re not using .git (shame on you, you should fell bad about that), go to step 2, for the cool ones open your favorite flavor console/terminal and create your dir & gitit :

Just to be shure, check if git folder is really there:

Ok, we should only see the .git folder, now we’re ready to add the dependencies using bower, we only need to request for Bootstrap CDN  and his dependencies (yes I’m talking of jQuery js/css files) will came to us, so type this:

and the result should look like this:

If you prefer to load Bootstrap and OpenLayers scripts using them CDN (rememeber to be testing this as non-local file -any local http server will works-, check out npm local-web-server), just go with it.

Now to the fun part -yeiii-, create our test-file let’s call it ol1-cdn.html, here I recommend go as raw as possible, just with something like this inside our BODY tag will work:

Inside HEAD tag:

Above our closing body tag, the real magic will be inside our ol-cdn.js file (line 5 from below), this is because even for testing purposes, putting your JS code inside your HTML it’s just wrong:

[/spb_text_block] [/spb_row] [spb_row parallax_video_height=”video-height” parallax_video_overlay=”none” parallax_image_height=”content-height” parallax_image_movement=”fixed” parallax_image_speed=”0.5″ row_overlay_opacity=”0″ width=”1/1″ el_position=”first last”] [spb_text_block pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

openlayers_monster[1]Step 2 – Displaying the map

Lets start with Immediately Invoked Function Expressions (IIFEs). IIFEs are an ideal solution for locally scoping global variables/properties and protecting your JavaScript codebase from outside interference (e.g. third-party libraries). Real life maps are part of bigger-complex applications so we’re looking for make it as modular and scalable as possible.

OpenLayers maps works using layers -wow-, this layers or array of layers are obects from class ol.layer, we’re using a function to retrieve thos layer(s) before we use them inside the map:

Lets starts with the OnLoad behavior, marked line shows where the result of previus step is being used:

This is the result

Next tutorial we’ll be loading KML files into this puppy. Thanks for reading.

Feeling sceptical about? Wacht it work here, you can download the files from this demo here or go to Github and clone it.

56343015[1]

[/spb_text_block] [/spb_row]
tortoisesvn

Export TortoiseSVN log to spreadsheet

By | Code, Software | No Comments
[spb_row parallax_video_height=”video-height” parallax_video_overlay=”none” parallax_image_height=”content-height” parallax_image_movement=”fixed” parallax_image_speed=”0.5″ row_overlay_opacity=”0″ width=”1/1″ el_position=”first last”] [spb_text_block title=”The Problem” icon=”fa-cloud” pb_margin_bottom=”no” pb_border_bottom=”no” width=”3/4″ el_position=”first”]

If you are looking for this kind of solution this ain’t your first rodeo in TortoiseSVN so we’ll asumme you don’t need a “how to check-in/out, merge, compare” files from your code repositories, so let’s get straight to the point shall we; the default log format is something like this:

Maybe functional but nothing what you could really use for client reporting purposes. So, and spreadsheet is the goal.

[/spb_text_block] [spb_single_image image=”12297″ image_size=”full” frame=”noframe” intro_animation=”none” full_width=”no” lightbox=”no” link_target=”_self” width=”1/4″ el_position=”last”] [spb_text_block title=”The Solution” icon=”fa-lightbulb-o” pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

Like the good things in life, it’s all about the little things, so a couple lines of code will retreive rescue, open favorite flavor of terminal and follow this:

This will create an XML file inside Project1 folder named current_log, we can open this XML using let’s say MS Excel

[/spb_text_block] [spb_single_image image=”12321″ image_size=”full” frame=”shadowframe” intro_animation=”fade-in” full_width=”no” lightbox=”yes” link_target=”_self” caption=”Result” width=”1/1″ el_position=”first last”] [/spb_row]
nodejs-1280x1024

NodeJS – learnyounode

By | Code, Software | No Comments
[spb_row parallax_video_height=”video-height” parallax_video_overlay=”none” parallax_image_height=”content-height” parallax_image_movement=”fixed” parallax_image_speed=”0.5″ row_overlay_opacity=”0″ width=”1/1″ el_position=”first last”] [spb_text_block pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

Last week we became interested in NodeJS enviroment, so one of the logical places to start is going to school, the NodeJS School.

I really want to keep it simple so the LEARNYOUNODE tutorials looks like the right thing to do, it came pretty much from ground zero to get an async-service-server.

You should know really something more than the basics of JS to get started but not a real deal breaker, new language learning curve is pretty much the same (any ecma based language should help).

So, learnyounode its really easy to install (one command line and it’s done), and its all about the console, check this screenshots:

 

So from excercise 1 to 6 it’s all about the basics, this is the solution to excercise 6:

[/spb_text_block] [spb_text_block pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

 THE GOAL: MAKE IT MODULAR

[/spb_text_block] [/spb_row] [spb_column width=”1/2″ el_position=”first”] [spb_text_block pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

Exercise 6 of 13 This problem is the same as the previous but introduces the concept of modules. You will need to create two files to solve this.

Create a program that prints a list of files in a given directory, filtered by t he extension of the files. The first argument is the directory name and the seco nd argument is the extension filter. Print the list of files (one file per line) to the console. You must use asynchronous I/O.

You must write a module file to do most of the work. The module must export a si ngle function that takes three arguments: the directory name, the filename exten sion string and a callback function, in that order. The filename extension argum ent must be the same as was passed to your program. i.e. don’t turn it in to a R egExp or prefix with “.” or do anything else but pass it to your module where yo u can do what you need to make your filter work.

The callback function must be called using the idiomatic node(err, data) convent ion. This convention stipulates that unless there’s an error, the first argument passed to the callback will be null, and the second will be your data. In this case the data will be your filtered list of files, as an Array. If you receive a n error, e.g. from your call to fs.readdir(), the callback must be called with the error, and only the error, as the first argument.

[/spb_text_block] [/spb_column] [spb_column width=”1/2″ el_position=”last”] [spb_text_block pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

You must not print directly to the console from your module file, only from your original program.

In the case of an error bubbling up to your original program file, simply check for it and print an informative message to the console. These four things is the contract that your module must follow.

  • Export a single function that takes exactly the arguments described.
  • Call the callback exactly once with an error or some data as described.
  • Don’t change anything else, like global variables or stdout.
  • Handle all the errors that may occur and pass them to the callback.

The benifit of having a contract is that your module can be used by anyone who e xpects this contract. So your module could be used by anyone else who does learn younode, or the verifier, and just work.

[/spb_text_block] [/spb_column] [spb_row parallax_video_height=”video-height” parallax_video_overlay=”none” parallax_image_height=”content-height” parallax_image_movement=”fixed” parallax_image_speed=”0.5″ row_overlay_opacity=”0″ width=”1/1″ el_position=”first last”] [spb_text_block pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

Main Script

Module

 

[/spb_text_block] [spb_text_block pb_margin_bottom=”no” pb_border_bottom=”no” width=”1/1″ el_position=”first last”]

Conclusions

At this point you shoud be really familiar with the code you are watching, so NodeJS is really interesting and highly recommendable for anyone, loose the fear!.

The next excercise goal is: Write a program that performs an HTTP GET request to a URL provided to you as th e first command-line argument. Write the String contents of each “data” event fr om the response to a new line on the console (stdout). We’ll leve that for another post, thanks for reading and thanks for your comments. (#WT right? I know)


 

Resources:

[/spb_text_block] [/spb_row]
Code-Optimization

XSLT template parse XML as HTML table

By | Code | No Comments

Code-OptimizationThe goal here is create an XSLT template to display a HTML table based on XML parsed data. Nothing fancy but really complicated if you try it using a third-party xslt software (like Altova StyleVision 2013/2014 which use their own xslt processor and generated templates only can be transformed using it, not cool Altova, not cool) , so back to the basics, open that SublimeText/Notepad++ or any simple text editor of your choice and let’s start with the data:

The XML object:

 Now, the core, our XSLT template:

In this first approach I’m avoiding to use COLSPAN and another real-life properties (implementation soon, I promise). So the result if we apply our XSLT will be like this:
And look like this:

[C1R1] [C2R1]
[C1R2] [C2R2]
[C1R3] [C2R3]

 

Still feeling sceptical?

[sf_button colour=”blue” type=”sf-icon-stroke” size=”standard” link=”http://www.xsltcake.com/slices/gNfh6i/2″ target=”_self” icon=”ss-write” dropshadow=”no” extraclass=””]Try it your self![/sf_button]

Thanks for reading and hope this was helpful.

 

5af1800dbd18b30ced7a98fd63f0fe1f411091a0da880f6bf4dcdd967cce8270

 


 Check : O Reilly XSLT 2nd Edition