Inlinks to a page of the web are often used as indicators of the authority of the page, because it is commonly felt that if a page is linked from many other pages it is worth looking at. According to a widely accepted model, the inlinks follow a power law. Outlinking analysis, on the contrary, has received less attention. Nevertheless, the outlink structure should be included in the description of the web graph and used for designing and testing the algorithms for the real web. The power law has been proposed also for the outlinks, but the experimental observation has shown that the distribution of the pages with a low number of outlinks is not well modeled by the power law. In this paper we propose a linking model based on a preferential attachment strategy and a uniform attachment strategy. Similar models have already been considered in the literature. The substantial novelty of our approach on the previous ones concerns the approximation technique applied to the steady state solution. With this technique the model appears to be well suited for describing both inlink and outlink distributions. The experimentation on two subsets of the real web shows that the two attachment strategies play a different role in the inlink and the outlink case.